de.flexiprovider.core.dsa
Class DSAPublicKey
java.lang.Object
|
+--de.flexiprovider.api.keys.PublicKey
|
+--de.flexiprovider.core.dsa.interfaces.DSAPublicKey
|
+--de.flexiprovider.core.dsa.DSAPublicKey
- All Implemented Interfaces:
- DSAKey, java.security.interfaces.DSAKey, java.security.interfaces.DSAPublicKey, Key, java.security.Key, java.security.PublicKey, java.io.Serializable
- public class DSAPublicKey
- extends DSAPublicKey
- implements DSAKey
This class implements the DSAPublicKey interface.
- Author:
- Thomas Wahrenbruch
- See Also:
DSAKeyFactory, Serialized Form
| Fields inherited from interface java.security.interfaces.DSAPublicKey |
serialVersionUID |
| Methods inherited from class java.lang.Object |
, clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.security.interfaces.DSAKey |
getParams |
| Methods inherited from interface java.security.Key |
getEncoded, getFormat |
DSAPublicKey
protected DSAPublicKey(FlexiBigInt y,
DSAParams params)
- The default constructor generates a DSA public key with the specified
parameters.
- Parameters:
y - the public y.params - the DSA parameters.
DSAPublicKey
protected DSAPublicKey(DSAPublicKeySpec keySpec)
- Construct a DSAPubKey out of the given key specification.
- Parameters:
keySpec - the key specification
getAlgorithm
public java.lang.String getAlgorithm()
- This function returns the name of the corresponding algorithm "DSA".
- Returns:
- "DSA".
getParameters
public DSAParams getParameters()
- This function returns the DSA parameters.
- Specified by:
getParameters in interface DSAKey
- Returns:
- the DSA parameters.
getValueY
public FlexiBigInt getValueY()
- This function returns the public y.
- Overrides:
getValueY in class DSAPublicKey
- Returns:
- the public y.
toString
public java.lang.String toString()
- Returns a human readable form of the key.
- Overrides:
toString in class java.lang.Object
- Returns:
- a human readable form of the key.
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals in class java.lang.Object
hashCode
public int hashCode()
- Overrides:
hashCode in class java.lang.Object
getOID
protected codec.asn1.ASN1ObjectIdentifier getOID()
- Overrides:
getOID in class PublicKey
- Returns:
- the OID to encode in the SubjectPublicKeyInfo structure
getAlgParams
protected codec.asn1.ASN1Type getAlgParams()
- Overrides:
getAlgParams in class PublicKey
- Returns:
- the algorithm parameters to encode in the SubjectPublicKeyInfo
structure
getKeyData
protected byte[] getKeyData()
- Overrides:
getKeyData in class PublicKey
- Returns:
- the keyData to encode in the SubjectPublicKeyInfo structure