Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix hardcoded public key auth negotiation #294

Merged
merged 1 commit into from
Jun 2, 2024
Merged

Fix hardcoded public key auth negotiation #294

merged 1 commit into from
Jun 2, 2024

Conversation

tomknig
Copy link
Contributor

@tomknig tomknig commented Jun 1, 2024

Authentication using RSA public keys was incorrectly hardcoded to use ssh-rsa, i.e., SHA1. This led to public keys set up to use rsa-sha2-256 or rsa-sha2-512 falling back to ssh-rsa and being rejected by modern SSH servers that are configured not to support SHA1 by default.

The solution derives the hash name from the public key instead of hardcoding it.

Authentication using rsa public keys were incorrectly hardcoded to use `ssh-rsa`, i.e., SHA1. This led to public keys set-up to use `rsa-sha2-256` or `rsa-sha2-512` falling back to `ssh-rsa` and being rejected by modern ssh servers that configured not to support SHA1 by default.

The solution derives the hash name from the public key instead of hardcoding it.
@Eugeny Eugeny merged commit 2bfe426 into Eugeny:main Jun 2, 2024
4 checks passed
@Eugeny
Copy link
Owner

Eugeny commented Jun 2, 2024

Thank you!

@all-contributors please add @tomknig for code

Copy link
Contributor

@Eugeny

I've put up a pull request to add @tomknig! 🎉

Eugeny pushed a commit that referenced this pull request Jun 2, 2024
Adds @tomknig as a contributor for code.

This was requested by Eugeny [in this
comment](#294 (comment))

[skip ci]

---------

Co-authored-by: allcontributors[bot] <46447321+allcontributors[bot]@users.noreply.github.com>
@tomknig
Copy link
Contributor Author

tomknig commented Jun 2, 2024

Thanks @Eugeny!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants