public final class SSHKey extends java.lang.Object implements FingerprintableKey
Key implementation for OpenSSH-compliant keys (RSA/DSA)| Constructor and Description |
|---|
SSHKey(KeyFormat keyFormat,
java.security.KeyPair keyPair) |
SSHKey(KeyFormat keyFormat,
java.security.PublicKey publicKey,
java.security.PrivateKey privateKey) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canSign() |
boolean |
canVerify() |
boolean |
equals(java.lang.Object o) |
java.util.Set<Algorithm> |
getAlgorithms() |
java.lang.String |
getFingerprint() |
java.lang.String |
getId() |
int |
hashCode() |
byte[] |
sign(Algorithm algorithm,
byte[] challengeHash) |
boolean |
verify(Algorithm algorithm,
byte[] challengeHash,
byte[] signatureBytes) |
public SSHKey(KeyFormat keyFormat, java.security.KeyPair keyPair)
public SSHKey(KeyFormat keyFormat, java.security.PublicKey publicKey, java.security.PrivateKey privateKey)
public java.lang.String getFingerprint()
getFingerprint in interface FingerprintableKeypublic java.util.Set<Algorithm> getAlgorithms()
getAlgorithms in interface Keypublic boolean verify(Algorithm algorithm, byte[] challengeHash, byte[] signatureBytes)
public byte[] sign(Algorithm algorithm, byte[] challengeHash)
public boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.ObjectCopyright © 2013-2017. All Rights Reserved.