Class SmartCardHSMKey
- java.lang.Object
-
- de.cardcontact.opencard.service.smartcardhsm.SmartCardHSMKey
-
- All Implemented Interfaces:
java.io.Serializable
,java.security.Key
,KeyRef
- Direct Known Subclasses:
SmartCardHSMPrivateKey
,SmartCardHSMSecretKey
public class SmartCardHSMKey extends java.lang.Object implements KeyRef
Reference to the private key on the SmartCardHSM- Author:
- lew
- See Also:
PrivateKeyRef
, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SmartCardHSMKey(byte keyRef, java.lang.String label, short keySize)
SmartCardHSMKey(byte keyRef, java.lang.String label, short keySize, java.lang.String algorithm)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getAlgorithm()
byte[]
getAlgorithms()
SmartCardHSMCardService
getCardService()
byte[]
getEncoded()
java.lang.String
getFormat()
KeyDomain
getKeyDomain()
byte[]
getKeyId()
byte
getKeyRef()
short
getKeySize()
java.lang.String
getLabel()
int
getUseCounter()
void
processKeyInfo(java.util.ArrayList<KeyDomain> keyDomains, byte[] a5)
Process the content of tag A5 returned in the SELECT command applied to a key FIDvoid
setAlgorithm(java.lang.String algorithm)
void
setAlgorithms(byte[] algorithms)
void
setCardService(SmartCardHSMCardService cardService)
void
setKeyDomain(KeyDomain keyDomain)
void
setKeyId(byte[] keyId)
void
setKeyRef(byte keyRef)
void
setKeySize(short keySize)
void
setLabel(java.lang.String label)
java.lang.String
toString()
-
-
-
Field Detail
-
RSA
public static final java.lang.String RSA
- See Also:
- Constant Field Values
-
EC
public static final java.lang.String EC
- See Also:
- Constant Field Values
-
AES
public static final java.lang.String AES
- See Also:
- Constant Field Values
-
-
Method Detail
-
getAlgorithm
public java.lang.String getAlgorithm()
- Specified by:
getAlgorithm
in interfacejava.security.Key
-
getEncoded
public byte[] getEncoded()
- Specified by:
getEncoded
in interfacejava.security.Key
-
getFormat
public java.lang.String getFormat()
- Specified by:
getFormat
in interfacejava.security.Key
-
setAlgorithm
public void setAlgorithm(java.lang.String algorithm)
-
getKeyRef
public byte getKeyRef()
-
setKeyRef
public void setKeyRef(byte keyRef)
-
getLabel
public java.lang.String getLabel()
-
setLabel
public void setLabel(java.lang.String label)
-
getKeyId
public byte[] getKeyId()
-
setKeyId
public void setKeyId(byte[] keyId)
-
getKeySize
public short getKeySize()
-
setKeySize
public void setKeySize(short keySize)
-
setAlgorithms
public void setAlgorithms(byte[] algorithms)
-
getAlgorithms
public byte[] getAlgorithms()
-
getUseCounter
public int getUseCounter()
-
setKeyDomain
public void setKeyDomain(KeyDomain keyDomain)
-
getKeyDomain
public KeyDomain getKeyDomain()
-
setCardService
public void setCardService(SmartCardHSMCardService cardService)
-
getCardService
public SmartCardHSMCardService getCardService()
-
processKeyInfo
public void processKeyInfo(java.util.ArrayList<KeyDomain> keyDomains, byte[] a5)
Process the content of tag A5 returned in the SELECT command applied to a key FID- Parameters:
a5
- the encoded tag A5
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-