Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Detect ambiguous usernames, maybe in all dangerous cases
This makes all the unit tests pass, as well as the journey tests that run locally. My guess is that the journey tests that run only on CI may pass as well. It also passes manual testing of specific cases of concern, by running `cargo install --path .` and then attempting the commands: gix clone 'ssh://-Fconfigfile@example.com/abc' gix clone -- '-Fconfigfile@example.com:abc/def' Previously, these passed -F... option arguments to ssh. Now they do not, instead refusing to run ssh and outputting: Error: Username '-Fconfigfile' could be mistaken for a command-line argument However, gix_transport::client::blocking_io::ssh::connect remains unchanged. It does not appear to use the username argument. If it should use it, then when that is added, it will also need to check for dangerous usernames. But it may be that the username is never needed just to pass `-G` for that check.
- Loading branch information