Documentation
¶
Index ¶
- func DigestsForSSH(sshPK ssh.PublicKey, v23PK, purpose, message []byte) ([]byte, security.Hash, error)
- func FromECDSAKey(key ssh.PublicKey) (security.PublicKey, error)
- func FromED25512Key(key ssh.PublicKey) (security.PublicKey, error)
- func HashedDigestsForSSH(sshPK ssh.PublicKey, v23PK, purpose, message []byte) ([]byte, security.Hash, error)
- func IsSupported(key ssh.PublicKey) bool
- func UnmarshalSSHECDSASignature(sig *ssh.Signature) (r, s []byte, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DigestsForSSH ¶
func DigestsForSSH(sshPK ssh.PublicKey, v23PK, purpose, message []byte) ([]byte, security.Hash, error)
DigestsForSSH returns a concatenation of the hashes of the public key, the message and the purpose. The openSSH and openSSL ECDSA code will hash this message again internally and hence these hashes must not be themselves hashed here to ensure compatibility with the Vanadium signature verification which uses the go crypto code so that a messages signed by the SSH agent/ssl code can be verified by the Vanadium code.
func FromECDSAKey ¶
FromECDSAKey creates a security.PublicKey from an ssh ECDSA key.
func FromED25512Key ¶
FromECDSAKey creates a security.PublicKey from an ssh ED25519 key.
func HashedDigestsForSSH ¶
func HashedDigestsForSSH(sshPK ssh.PublicKey, v23PK, purpose, message []byte) ([]byte, security.Hash, error)
HashedDigestsForSSH hashes the digests returned by DigestsForSSH using an appropriate hash function for the ssh key. The ED25519 implementation in openSSH does not rehash internally and consequently this is needed for compatibility with the Vanadium code.
func IsSupported ¶
IsSupported returns true if the suplied ssh key type is supported.
Types ¶
This section is empty.