Retrieves user identities, where keys is a possible array of public
keys for authentication.
OptionalgetOptional method that may be implemented to support agent forwarding. Callback
should be invoked with a Duplex stream to be used to communicate with your agent/
You will probably want to utilize AgentProtocol as agent forwarding is an
OpenSSH feature, so the stream needs to be able to
transmit/receive OpenSSH agent protocol packets.
Signs the datawith the given public key, and calls back with its signature. Note that, in the current implementation, "options" is always an empty object.
OptionalmaybeCb: (err: Error | null, signature?: Buffer<ArrayBufferLike>) => void
An
ssh2agent that signs the SSH handshake with an Ed25519 KMS key, so a private key never has to exist in the process, in SSM, or in Secrets Manager.KMS's
ED25519_SHA_512withMessageType: RAWis pure Ed25519 over the message, which is exactly whatssh-ed25519signs. So the 64 bytes KMS returns are the signature ssh2 wants verbatim:authPKwraps it into the SSH blob itself, andconvertSignaturerewrites onlyssh-dssandecdsa-*. Nothing has to be transcoded here.Ed25519 has exactly one signing algorithm, so unlike the RSA path there is no
rsa-sha2-*negotiation to mirror between what ssh2 offers and what we sign with.