Skip to content

Add method to do OpenSSH authentication with hash algo specified - #678

Open
lanshubo wants to merge 1 commit into
Eugeny:mainfrom
mujin:support_openssh_algo_spec
Open

Add method to do OpenSSH authentication with hash algo specified#678
lanshubo wants to merge 1 commit into
Eugeny:mainfrom
mujin:support_openssh_algo_spec

Conversation

@lanshubo

Copy link
Copy Markdown

authenticate_openssh_cert currently hardcodes RSA-SHA-512 for RSA private key signing, causing failures against legacy servers that only accept RSA-SHA-1. This PR adds a new method variant that accepts a PublicKeyOrCertificate argument so callers can control the signing algorithm explicitly.

// in ssh-key, this will forcly use RSA-SHA-512 to sign
signature::Signer::try_sign(key.deref(), buffer)?
    .encoded()?
    .encode(&mut *buffer)?;

@lanshubo
lanshubo force-pushed the support_openssh_algo_spec branch from 8338d2f to 259ed35 Compare March 31, 2026 08:12
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.

1 participant