Documented working directory behaviour for `cargo test`, `cargo bench` and `cargo run`
Fixes#11852. Updated the respective man-pages of `cargo test`, `cargo bench` and `cargo run` to include the information of the working directory of the executables. Added a comment in the code of `cargo run` where the default behaviour (the package's root directory) is overridden.
Add the old github keys as revoked
The patch to update the bundled ssh github host key did not change anything for users who already had connected to github one time before via ssh: if the attacker had access to the old key, they'd be vulnerable to MITM attacks as their known_hosts file would list the old github key. Only if they connected again to github without attacker access, or if they saw the announcement of the key rotation, they would update their key.
There is sadly no other way to distribute revocations of old host keys to clients other than to bundle them with client software.
cc #11883
The patch to update the bundled ssh github host key did not
change anything for users who already had connected to github
one time before via ssh: if the attacker had access to the old
key, they'd be vulnerable to MITM attacks as their known_hosts
file would list the old github key. Only if they connected
again to github without attacker access, or if they saw the
announcement of the key rotation, they would update their key.
There is sadly no other way to distribute revocations of old host
keys to clients other than to bundle them with client software.
Update proptest
This updates proptest from 0.9.1 to 1.1.0. This helps drop some old, unsupported dependencies like `fuchsia-cprng` from an old version of `rand`.
Changelog: https://github.com/proptest-rs/proptest/blob/master/proptest/CHANGELOG.md
I don't see any particularly relevant breaking changes for our use.
Added new GitHub RSA Host Key
GitHub rotated their RSA host key which means that cargo needs to update it. Thankfully the other keys were not rotated so the impact depends on how cargo connected to github.
Refs https://github.blog/2023-03-23-we-updated-our-rsa-ssh-host-key/
doc: Fix registries.name.index for sparse
A very minor documentation update. `registries.name.index` doesn't have to be a git URL, it can also be a sparse one.
docs: fix typos in `cargo_compile/mod.rs`
### What does this PR try to resolve?
We've got a couple of typos in the docs for `cargo_compile/mod.rs` so I've addressed them.
### How should we test and review this PR?
Just needs a quick proofread
### Additional information
N/A
docs(contrib): Move higher level resolver docs into doc comments
This is a follow up to #11809.
I chose `ops::resolve` for most of the old documentation as this because the docs cover the
higher level details that include it, like `Cargo.lock` file, while
`core::resolver` is more of the algorithm.
docs(contrib): Pull impl info out of architecture
This is a follow up to #11809.
Personally, I found mixing this stuff with architecture less than ideal as it buried the more practical information among details that might not have been as important. With us moving architecture information into doc comments, this provides us an opportunity to rectify this.
Not a fan of the name of this chapter but its a start.
I've left in the old architecture chapter as there is still content to find a home for (resolver).
Update curl-sys
This updates curl-sys from 0.4.59 to 0.4.61. This corresponds to curl 7.86.0 to 8.0.1.
Changelog: https://curl.se/changes.htmlCloses#11746
Poll loop fixes
### What does this PR try to resolve?
A couple of minor issues. See individual commits.
### How should we test and review this PR?
The existing test suite should have sufficient coverage.
### Additional information
(I have 5 apparently unrelated failures locally when running `cargo test`)
I chose `ops::resolve` as the place for this as the docs cover the
higher level details, including the `Cargo.lock` file, while
`core::resolver` is more of the algorithm.
Personally, I found mixing this stuff with architecture less than ideal
as it buried the more practical information among details that might not
have been as important. With us moving architecture information into
doc comments, this provides us an opportunity to rectify this.
Not a fan of the name of this chapter but its a start.
I've left in the old architecture chapter as there is still content to
find a home for (resolver).
Handle case mismatches when looking up env vars in the Config snapshot
### What does this PR try to resolve?
Fixes#11814.
Windows environment variables are case-insensitive, which causes problems when looking them up in the `Config` env snapshot.
This PR adds another member (`case_insensitive_env`) in `Config` that maps upper-cased keys to their original values in the env (for example, `"PATH" => "Path"`). If lookup in `self.env` fails, this PR converts the key to upper case and looks it up in `self.case_insensitive_env` to obtain the correct key name if it exists (on Windows only).
### How should we test and review this PR?
Please see the new tests in `testsuite/config.rs` and `testsuite/cargo_command.rs`.
### Additional information
Currently, this uses `str::to_uppercase` to uppercase the keys. This requires key to be valid UTF-8, and may disagree with how the OS uppercases things (see the link in [this comment](https://github.com/rust-lang/cargo/issues/11814#issuecomment-1462870983) for details).