For CRT private keys, see RSAPrivateCrtKeyImpl. We need separate classes to ensure correct behavior in instanceof checks, etc.
Note
RSA keys must be at least 512 bits long
RSAPrivateCrtKeyImpl
, RSAKeyFactory
Modifier and Type | Field and Description |
---|---|
private final BigInteger | |
private final transient AlgorithmParameterSpec | |
private final BigInteger | |
private static final long | |
private final transient RSAUtil. |
Access | Constructor and Description |
---|---|
pack-priv | RSAPrivateKeyImpl(RSAUtil.
Construct a key from its components. |
Modifier and Type | Method and Description |
---|---|
public String | getAlgorithm()
Overrides sun. Implements java. |
public BigInteger | |
public AlgorithmParameterSpec | getParams()
Overrides default java. |
public BigInteger | getPrivateExponent()
Implements java. |
private void | readObject(ObjectInputStream
the stream)
Restores the state of this object from the stream.
ObjectInputStream from which data is read |
public String |
d | back to summary |
---|---|
private final BigInteger d |
keyParams | back to summary |
---|---|
private final transient AlgorithmParameterSpec keyParams |
n | back to summary |
---|---|
private final BigInteger n |
serialVersionUID | back to summary |
---|---|
private static final long serialVersionUID Hides sun. |
type | back to summary |
---|---|
private final transient RSAUtil. |
RSAPrivateKeyImpl | back to summary |
---|---|
pack-priv RSAPrivateKeyImpl(RSAUtil. Construct a key from its components. Used by the RSAKeyFactory and the RSAKeyPairGenerator. |
getAlgorithm | back to summary |
---|---|
public String getAlgorithm() Overrides sun. Implements java. Doc from java. Returns the standard algorithm name for this key. For example, "DSA" would indicate that this key is a DSA key. See the key related sections (KeyFactory, KeyGenerator, KeyPairGenerator, and SecretKeyFactory) in the Java Security Standard Algorithm Names Specification for information about standard key algorithm names. |
getModulus | back to summary |
---|---|
public BigInteger getModulus() Implements java. Doc from java. Returns the modulus.
|
getParams | back to summary |
---|---|
public AlgorithmParameterSpec getParams() Overrides default java. Doc from java. Returns the parameters associated with this key. The parameters are optional and may be either explicitly specified or implicitly created during key pair generation.
|
getPrivateExponent | back to summary |
---|---|
public BigInteger getPrivateExponent() Implements java. Doc from java. Returns the private exponent.
|
readObject | back to summary |
---|---|
private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException Hides sun. Restores the state of this object from the stream. Deserialization of this object is not supported.
|
toString | back to summary |
---|---|
public String toString() Overrides java. Doc from java. Returns a string representation of the object. |