|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.ibm.security.pkcsutil.PKCSDerObject
com.ibm.security.pkcs8.PrivateKeyInfo
com.ibm.crypto.pkcs11impl.provider.RSAPrivateKey
public final class RSAPrivateKey
A PKCS11 RSA Private Key
| Field Summary |
|---|
| Fields inherited from class com.ibm.security.pkcs8.PrivateKeyInfo |
|---|
version |
| Constructor Summary | |
|---|---|
RSAPrivateKey(com.ibm.pkcs11.PKCS11Session session,
com.ibm.pkcs11.PKCS11Object object,
byte[] id,
byte[] subject,
java.lang.String label,
java.lang.Boolean isToken,
java.lang.Boolean isSensitive,
java.lang.Boolean isSign,
java.lang.Boolean isDecrypt,
java.lang.Boolean isUnwrap,
java.lang.Boolean isExtractable,
java.math.BigInteger modulus,
java.math.BigInteger publicExponent)
Creates a RSA private hardware key |
|
RSAPrivateKey(com.ibm.pkcs11.PKCS11Session session,
com.ibm.pkcs11.PKCS11Object object,
byte[] id,
byte[] subject,
java.lang.String label,
java.lang.Boolean isToken,
java.lang.Boolean isSensitive,
java.lang.Boolean isSign,
java.lang.Boolean isDecrypt,
java.lang.Boolean isUnwrap,
java.lang.Boolean isExtractable,
java.math.BigInteger modulus,
java.math.BigInteger publicExponent,
java.math.BigInteger privateExponent,
java.math.BigInteger prime1,
java.math.BigInteger prime2,
java.math.BigInteger exponent1,
java.math.BigInteger exponent2,
java.math.BigInteger coefficient)
Creates a RSA private hardware key |
|
| Method Summary | |
|---|---|
java.lang.String |
getAlgorithm()
Get algorithm which always returns RSA |
java.lang.Boolean |
getAlwaysSensitive()
Return is this key AlwaysSensitive |
java.lang.Integer |
getAuthPinFlags()
Returns the auth pin flags |
java.math.BigInteger |
getCoefficient()
Returns the coefficient. |
java.math.BigInteger |
getCrtCoefficient()
Returns the coefficient. |
java.lang.Boolean |
getDecrypt()
Return if the key can be used for decryption. |
java.lang.Boolean |
getDerive()
Returns if key supports key derivation |
java.util.Date |
getEndDate()
Returns the end date |
java.math.BigInteger |
getExponent1()
Returns the exponent1. |
java.math.BigInteger |
getExponent2()
Returns the exponent2. |
java.lang.Boolean |
getExtractable()
Return if this key can be wrapped by another key. |
java.lang.String |
getFormat()
Get format which always returns PKCS#11 |
byte[] |
getID()
Return the ID |
java.lang.Integer |
getKeyType()
Return the key type |
java.lang.String |
getLabel()
Return the label of the key. |
java.lang.Boolean |
getLocal()
Returns true if key was either: 1, generated locally with a C_GenerateKey or C_GenerateKeyPair call 2, created with a C_CopyObject call as a copy of a key which had its CKA_LOCAL attrobute set to TRUE |
java.lang.Boolean |
getModifiable()
Returns if the attributes of the are modifiable. |
java.math.BigInteger |
getModulus()
Return the modulus. |
java.lang.Boolean |
getNeverExtractable()
Return is this key Never Extractable |
com.ibm.pkcs11.PKCS11Object |
getObject()
Return the PKCS11Object |
java.math.BigInteger |
getPrime1()
Returns the prime1. |
java.math.BigInteger |
getPrime2()
Returns the prime2. |
java.math.BigInteger |
getPrimeExponentP()
Returns the exponent1. |
java.math.BigInteger |
getPrimeExponentQ()
Returns the exponent2. |
java.math.BigInteger |
getPrimeP()
Returns the prime1. |
java.math.BigInteger |
getPrimeQ()
Returns the prime2. |
java.lang.Boolean |
getPrivate()
Returns if the key is a private object |
java.math.BigInteger |
getPrivateExponent()
Return the private exponent. |
java.math.BigInteger |
getPublicExponent()
Returns the public exponent. |
java.lang.Boolean |
getSecondaryAuth()
Returns if the key requires secondary authentication |
java.lang.Boolean |
getSensitive()
Returns if the key is sensitive |
com.ibm.pkcs11.PKCS11Session |
getSession()
Return the session associated with the key. |
java.lang.Boolean |
getSign()
Return if this key can be used to create a signature |
java.lang.Boolean |
getSignRecover()
Return if this key supports sign recover |
java.util.Date |
getStartDate()
Returns the start date |
byte[] |
getSubject()
Return the subject of the key |
java.lang.Boolean |
getToken()
Returns if the key is a token object |
java.lang.Boolean |
getUnwrap()
Return if the key supports unwrapping other keys. |
java.lang.String |
toString()
Return a human readable version of the RSA private key. |
| Methods inherited from class com.ibm.security.pkcs8.PrivateKeyInfo |
|---|
addAttribute, addAttributes, clone, encode, equals, getAlgorithmId, getAttribute, getAttributes, getEncoded, getKeyBytes, hasAttribute, hasAttributes, hashCode, parseKey, parseKey |
| Methods inherited from class com.ibm.security.pkcsutil.PKCSDerObject |
|---|
encode, getObjectIdentifier, write |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public RSAPrivateKey(com.ibm.pkcs11.PKCS11Session session,
com.ibm.pkcs11.PKCS11Object object,
byte[] id,
byte[] subject,
java.lang.String label,
java.lang.Boolean isToken,
java.lang.Boolean isSensitive,
java.lang.Boolean isSign,
java.lang.Boolean isDecrypt,
java.lang.Boolean isUnwrap,
java.lang.Boolean isExtractable,
java.math.BigInteger modulus,
java.math.BigInteger publicExponent)
throws java.security.InvalidKeyException
session - the PKCS#11 session associated with the keyobject - the PKCS11 object that is the actaully representation of the key
to the hardware.ID - The identifier for this key.subject - Subject of this keylabel - Label of this keyisToken - Is this key a token?isSensitive - Is this key sensitive?isSign - Can this key be used for signature creation.isDecrypt - Can the key be used to decrypt data.isUnwrap - Can the key be used to unwrap another key.isExtractable - Can the key be wrapped by another key.modulus - Modulus of the keyPublicExponent - the public exponent of the key.
java.security.InvalidKeyException
public RSAPrivateKey(com.ibm.pkcs11.PKCS11Session session,
com.ibm.pkcs11.PKCS11Object object,
byte[] id,
byte[] subject,
java.lang.String label,
java.lang.Boolean isToken,
java.lang.Boolean isSensitive,
java.lang.Boolean isSign,
java.lang.Boolean isDecrypt,
java.lang.Boolean isUnwrap,
java.lang.Boolean isExtractable,
java.math.BigInteger modulus,
java.math.BigInteger publicExponent,
java.math.BigInteger privateExponent,
java.math.BigInteger prime1,
java.math.BigInteger prime2,
java.math.BigInteger exponent1,
java.math.BigInteger exponent2,
java.math.BigInteger coefficient)
throws java.security.InvalidKeyException
session - the PKCS#11 session associated with the keyobject - the PKCS11 object that is the actaully representation of the key
to the hardware.ID - The identifier for this key.subject - Subject of this keylabel - Label of this keyisToken - Is this key a token?isSensitive - Is this key sensitive?isSign - Can this key be used for signature creation.isDecrypt - Can the key be used to decrypt data.isUnwrap - Can the key be used to unwrap another key.isExtractable - Can the key be wrapped by another key.modulus - Modulus of the keyPublicExponent - the public exponent of the key.PrivateExponent - the private exponent of the key.Prime1 - the prime one of the key.Prime2 - the prime two of the key.exponent1 - the exponent one of the key.exponent2 - the exponent two of the key.coefficient - the coefficient of the key.
java.security.InvalidKeyException| Method Detail |
|---|
public com.ibm.pkcs11.PKCS11Object getObject()
getObject in interface PKCS11Keypublic java.lang.Boolean getToken()
getToken in interface PKCS11Keypublic java.lang.Boolean getPrivate()
getPrivate in interface PKCS11Keypublic java.lang.String getLabel()
getLabel in interface PKCS11Keypublic java.lang.Boolean getModifiable()
getModifiable in interface PKCS11Keypublic java.lang.Integer getKeyType()
getKeyType in interface PKCS11Keypublic byte[] getID()
getID in interface PKCS11Keypublic java.util.Date getStartDate()
getStartDate in interface PKCS11Keypublic java.util.Date getEndDate()
getEndDate in interface PKCS11Keypublic java.lang.Boolean getDerive()
getDerive in interface PKCS11Keypublic java.lang.Boolean getLocal()
getLocal in interface PKCS11Keypublic byte[] getSubject()
getSubject in interface PKCS11PrivateKeypublic java.lang.Boolean getSensitive()
getSensitive in interface PKCS11PrivateKeypublic java.lang.Boolean getSecondaryAuth()
getSecondaryAuth in interface PKCS11PrivateKeypublic java.lang.Integer getAuthPinFlags()
getAuthPinFlags in interface PKCS11PrivateKeypublic java.lang.Boolean getDecrypt()
getDecrypt in interface PKCS11PrivateKeypublic java.lang.Boolean getSign()
getSign in interface PKCS11PrivateKeypublic java.lang.Boolean getSignRecover()
getSignRecover in interface PKCS11PrivateKeypublic java.lang.Boolean getUnwrap()
getUnwrap in interface PKCS11PrivateKeypublic java.lang.Boolean getExtractable()
getExtractable in interface PKCS11PrivateKeypublic java.lang.Boolean getAlwaysSensitive()
getAlwaysSensitive in interface PKCS11PrivateKeypublic java.lang.Boolean getNeverExtractable()
getNeverExtractable in interface PKCS11PrivateKeypublic java.math.BigInteger getModulus()
getModulus in interface PKCS11RSAPrivateKeygetModulus in interface java.security.interfaces.RSAKeypublic java.math.BigInteger getPublicExponent()
getPublicExponent in interface PKCS11RSAPrivateKeygetPublicExponent in interface java.security.interfaces.RSAPrivateCrtKeypublic java.math.BigInteger getPrivateExponent()
getPrivateExponent in interface PKCS11RSAPrivateKeygetPrivateExponent in interface java.security.interfaces.RSAPrivateKeypublic java.math.BigInteger getPrime1()
getPrime1 in interface PKCS11RSAPrivateKeypublic java.math.BigInteger getPrime2()
getPrime2 in interface PKCS11RSAPrivateKeypublic java.math.BigInteger getExponent1()
getExponent1 in interface PKCS11RSAPrivateKeypublic java.math.BigInteger getExponent2()
getExponent2 in interface PKCS11RSAPrivateKeypublic java.math.BigInteger getCoefficient()
getCoefficient in interface PKCS11RSAPrivateKeypublic java.math.BigInteger getPrimeP()
getPrimeP in interface java.security.interfaces.RSAPrivateCrtKeypublic java.math.BigInteger getPrimeQ()
getPrimeQ in interface java.security.interfaces.RSAPrivateCrtKeypublic java.math.BigInteger getPrimeExponentP()
getPrimeExponentP in interface java.security.interfaces.RSAPrivateCrtKeypublic java.math.BigInteger getPrimeExponentQ()
getPrimeExponentQ in interface java.security.interfaces.RSAPrivateCrtKeypublic java.math.BigInteger getCrtCoefficient()
getCrtCoefficient in interface java.security.interfaces.RSAPrivateCrtKeypublic com.ibm.pkcs11.PKCS11Session getSession()
getSession in interface PKCS11Keypublic java.lang.String toString()
toString in class com.ibm.security.pkcs8.PrivateKeyInfopublic java.lang.String getFormat()
getFormat in interface java.security.KeygetFormat in class com.ibm.security.pkcs8.PrivateKeyInfopublic java.lang.String getAlgorithm()
getAlgorithm in interface java.security.KeygetAlgorithm in class com.ibm.security.pkcs8.PrivateKeyInfo
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||