public class RSAPublicKeyTemplate extends RSAKeyTemplate implements java.security.interfaces.RSAPublicKey
Description:
RSAPublicKeyTemplate with RSAKeyTemplate plus:
CK_ATTRIBUTE(CKA_CLASS, CKO_PUBLIC_KEY)
CK_ATTRIBUTE(CKA_PRIVATE, false)
CK_ATTRIBUTE(CKA_PUBLIC_EXPONENT, CardTemplate.toByteArray(publicExponent))
CK_ATTRIBUTE(CKA_MODULUS_BITS, spec.getKeysize()
encoded, modulus, OZET_ALICIspecattributes, keyId, label, logger| Constructor and Description |
|---|
RSAPublicKeyTemplate(java.lang.String label,
java.security.spec.RSAKeyGenParameterSpec spec)
Key Template with default RSA Public Key Parameters
|
RSAPublicKeyTemplate(java.lang.String label,
java.security.interfaces.RSAPublicKey publicKey)
Key Template with RSA Public Key To import, default RSAPublicKeyTemplate plus:
|
| Modifier and Type | Method and Description |
|---|---|
RSAPublicKeyTemplate |
getAsExtractableTemplate()
convert as Exportable Public Key Template, adding:
|
RSAPublicKeyTemplate |
getAsTokenTemplate(boolean verify,
boolean encrypt)
convert as User Token Template, adding:
|
RSAPublicKeyTemplate |
getAsTokenTemplate(boolean verify,
boolean encrypt,
boolean isWrap) |
RSAPublicKeyTemplate |
getAsWrapperTemplate()
convert as Wrapper Public Key Template, adding:
|
java.math.BigInteger |
getPublicExponent() |
getAlgorithm, getKeysize, getModulusgetSpecadd, containsAttribute, getAttribute, getAttributes, getAttributesAsArr, getEncoded, getFormat, getKeyId, getLabel, remove, setKeyIdpublic RSAPublicKeyTemplate(java.lang.String label,
java.security.spec.RSAKeyGenParameterSpec spec)
label - spec - public RSAPublicKeyTemplate(java.lang.String label,
java.security.interfaces.RSAPublicKey publicKey)
CK_ATTRIBUTE(CKA_MODULUS, modulusBytes)
CK_ATTRIBUTE(CKA_ID, id(SHA1 digest of Modulus))
label - publicKey - public java.math.BigInteger getPublicExponent()
getPublicExponent in interface java.security.interfaces.RSAPublicKeypublic RSAPublicKeyTemplate getAsTokenTemplate(boolean verify, boolean encrypt)
CK_ATTRIBUTE(CKA_TOKEN, true)
CK_ATTRIBUTE(CKA_ENCRYPT, encrypt)
CK_ATTRIBUTE(CKA_VERIFY, verify)
verify - encrypt - public RSAPublicKeyTemplate getAsTokenTemplate(boolean verify, boolean encrypt, boolean isWrap)
public RSAPublicKeyTemplate getAsWrapperTemplate()
CK_ATTRIBUTE(CKA_TOKEN, false)
CK_ATTRIBUTE(CKA_WRAP, true)
public RSAPublicKeyTemplate getAsExtractableTemplate()
CK_ATTRIBUTE(CKA_TOKEN, false)
Copyright © 2025. All rights reserved.