Method GetFingerprint
- Namespace
- SshSharp
- Assembly
- SshSharp.dll
GetFingerprint(HashAlgorithmName)
The fingerprint with hashAlgorithm, as ssh-keygen -l -E prints it: SHA256
gives Fingerprint, and MD5 the legacy MD5:aa:bb:... form that older tools and
inventories still show.
[SuppressMessage("Security", "CA5351", Justification = "An MD5 fingerprint only names a key for display, as ssh-keygen -E md5 does; nothing is trusted on it.")]
public string GetFingerprint(HashAlgorithmName hashAlgorithm)
Parameters
hashAlgorithmHashAlgorithmNameSHA256 or MD5.
Returns
Exceptions
- ArgumentException
hashAlgorithmis not SHA256 or MD5.