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

[SSHD-1216] Server-side server-sig-algs KEX extension #204

Merged
merged 1 commit into from
Oct 16, 2021

Conversation

tomaswolf
Copy link
Member

Provide a default implementation for the server-side SSH_MSG_EXT_INFO
message sending including the server-sig-algs KEX extension.[1]

A server that implements the rsa-sha2-512 or rsa-sha2-256 signature
algorithms should implement this extension, otherwise even clients that
also have these signature algorithms may fall back to ssh-rsa to avoid
authentication penalties.[2]

Apache MINA sshd servers by default do implement the SHA-2 RSA
signatures, and an Apache MINA sshd client by default does request KEX
extension information and does handle the server-sig-algs extension. So
an Apache MINA sshd server should by default implement this extension.

This implementation sends the server-sig-algs extension record once at
the end of the initial key exchange.

[1] https://tools.ietf.org/html/rfc8308
[2] https://tools.ietf.org/html/rfc8332#section-3.3

Provide a default implementation for the server-side SSH_MSG_EXT_INFO
message sending including the server-sig-algs KEX extension.[1]

A server that implements the rsa-sha2-512 or rsa-sha2-256 signature
algorithms should implement this extension, otherwise even clients that
also have these signature algorithms may fall back to ssh-rsa to avoid
authentication penalties.[2]

Apache MINA sshd servers by default do implement the SHA-2 RSA
signatures, and an Apache MINA sshd client by default does request KEX
extension information and does handle the server-sig-algs extension. So
an Apache MINA sshd server should by default implement this extension.

This implementation sends the server-sig-algs extension record once at
the end of the initial key exchange.

[1] https://tools.ietf.org/html/rfc8308
[2] https://tools.ietf.org/html/rfc8332#section-3.3
@benhumphreys
Copy link

Many thanks for this @tomaswolf
I've dropped a snapshot build of your branch into Bitbucket Server to do some testing and it looks great! I've tested with OpenSSH 8.1p1 and 8.8p1 and it works as expected, with both resulting in the use of rsa-sha2-512.

I've also tested with OpenSSH 6.6.1p1 and it works as I'd expect; it doesn't send server-sig-algs because the client doesn't send ext-info-s.

@tomaswolf tomaswolf merged commit 2e5cf6f into apache:master Oct 16, 2021
@tomaswolf
Copy link
Member Author

Thanks for double-checking, @benhumphreys .

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.

None yet

2 participants