Class AsymmetricEdDSAPublicKey
java.lang.Object
org.bouncycastle.crypto.asymmetric.AsymmetricEdDSAKey
org.bouncycastle.crypto.asymmetric.AsymmetricEdDSAPublicKey
- All Implemented Interfaces:
AsymmetricKey
,AsymmetricPublicKey
,Key
public final class AsymmetricEdDSAPublicKey
extends AsymmetricEdDSAKey
implements AsymmetricPublicKey
Edwards Curve Diffie-Hellman (XDH) public keys.
-
Constructor Summary
ConstructorsConstructorDescriptionAsymmetricEdDSAPublicKey
(byte[] encoding) Construct a key from an encoding of a SubjectPublicKeyInfo.AsymmetricEdDSAPublicKey
(Algorithm algorithm, byte[] keyData) -
Method Summary
Modifier and TypeMethodDescriptionboolean
Return true if o is an equivalent key to this.byte[]
Return an ASN.1 encoding of the key wrapped in a PrivateKeyInfo or a SubjectPublicKeyInfo structure.byte[]
int
hashCode()
Return the hashCode for the key.Methods inherited from class org.bouncycastle.crypto.asymmetric.AsymmetricEdDSAKey
checkApprovedOnlyModeStatus, getAlgorithm, isThreadCorrectMode, zeroize
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.bouncycastle.crypto.Key
getAlgorithm
-
Constructor Details
-
AsymmetricEdDSAPublicKey
-
AsymmetricEdDSAPublicKey
public AsymmetricEdDSAPublicKey(byte[] encoding) Construct a key from an encoding of a SubjectPublicKeyInfo.- Parameters:
encoding
- the DER encoding of the key.
-
-
Method Details
-
getPublicData
public byte[] getPublicData() -
getEncoded
public byte[] getEncoded()Description copied from interface:AsymmetricKey
Return an ASN.1 encoding of the key wrapped in a PrivateKeyInfo or a SubjectPublicKeyInfo structure.- Specified by:
getEncoded
in interfaceAsymmetricKey
- Returns:
- an encoding of a PrivateKeyInfo or a SubjectPublicKeyInfo structure.
-
equals
Description copied from interface:Key
Return true if o is an equivalent key to this. -
hashCode
public int hashCode()Description copied from interface:Key
Return the hashCode for the key.
-