Method WithCertificate
- Namespace
- SshSharp
- Assembly
- SshSharp.dll
WithCertificate(SshCertificate)
This key paired with an OpenSSH user certificate for it (id_ed25519-cert.pub, made with ssh-keygen -s): authentication
then presents the certificate, which servers that trust its authority (TrustedUserCAKeys) accept without an authorized_keys
entry. The returned key shares this key's private material: disposing this key disposes both.
public SshPrivateKey WithCertificate(SshCertificate certificate)
Parameters
certificateSshCertificate
Returns
Exceptions
- ArgumentException
The certificate is not a user certificate, or certifies a different key.