public abstract class APDU
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
APDU.Type |
Modifier and Type | Field and Description |
---|---|
protected byte |
cla |
protected TPSBuffer |
data |
static int |
DEFAULT_APDU_SIZE |
protected byte |
ins |
protected TPSBuffer |
mac |
protected byte |
p1 |
protected byte |
p2 |
protected TPSBuffer |
plainText |
protected TPSBuffer |
trailer |
Modifier and Type | Method and Description |
---|---|
void |
dump() |
byte |
getCLA() |
TPSBuffer |
getData() |
TPSBuffer |
getDataToMAC() |
TPSBuffer |
getEncoding()
Retrieves APDU's encoding.
|
byte |
getINS() |
TPSBuffer |
getMAC() |
byte |
getP1() |
byte |
getP2() |
APDU.Type |
getType() |
void |
secureMessage(org.mozilla.jss.pkcs11.PK11SymKey encKey,
byte protocol) |
void |
secureMessageSCP02(org.mozilla.jss.pkcs11.PK11SymKey encKey) |
void |
setMAC(TPSBuffer theMac) |
void |
setTrailer(TPSBuffer theTrailer) |
public static int DEFAULT_APDU_SIZE
protected byte cla
protected byte ins
protected byte p1
protected byte p2
protected TPSBuffer data
protected TPSBuffer plainText
protected TPSBuffer mac
protected TPSBuffer trailer
public APDU()
public APDU(APDU otherAPDU)
public void setMAC(TPSBuffer theMac)
public void setTrailer(TPSBuffer theTrailer)
public TPSBuffer getEncoding()
data
- the result buffer which will contain the actual data
including the APDU header, data, and pre-calculated mac.public TPSBuffer getDataToMAC()
public void secureMessage(org.mozilla.jss.pkcs11.PK11SymKey encKey, byte protocol) throws EBaseException
EBaseException
public void secureMessageSCP02(org.mozilla.jss.pkcs11.PK11SymKey encKey) throws EBaseException
EBaseException
public APDU.Type getType()
public TPSBuffer getData()
public TPSBuffer getMAC()
public byte getCLA()
public byte getINS()
public byte getP1()
public byte getP2()
public void dump()