|
JMRTD 0.4.6 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jmrtd.SecureMessagingWrapper
public class SecureMessagingWrapper
Secure messaging wrapper for apdus. Based on Section E.3 of ICAO-TR-PKI.
| Constructor Summary | |
|---|---|
SecureMessagingWrapper(SecretKey ksEnc,
SecretKey ksMac)
Constructs a secure messaging wrapper based on the secure messaging session keys. |
|
SecureMessagingWrapper(SecretKey ksEnc,
SecretKey ksMac,
long ssc)
Constructs a secure messaging wrapper based on the secure messaging session keys and the initial value of the send sequence counter. |
|
| Method Summary | |
|---|---|
long |
getSendSequenceCounter()
Gets the current value of the send sequence counter. |
ResponseAPDU |
unwrap(ResponseAPDU responseAPDU,
int len)
Unwraps the apdu buffer rapdu of a response apdu. |
CommandAPDU |
wrap(CommandAPDU commandAPDU)
Wraps the apdu buffer capdu of a command apdu. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SecureMessagingWrapper(SecretKey ksEnc,
SecretKey ksMac)
throws GeneralSecurityException
0L.
ksEnc - the session key for encryptionksMac - the session key for macs
GeneralSecurityException - when the available JCE providers cannot provide the necessary
cryptographic primitives ("DESede/CBC/Nopadding" Cipher,
"ISO9797Alg3Mac" Mac).
public SecureMessagingWrapper(SecretKey ksEnc,
SecretKey ksMac,
long ssc)
throws GeneralSecurityException
ksEnc - the session key for encryptionksMac - the session key for macsssc - the initial value of the send sequence counter
GeneralSecurityException - when the available JCE providers cannot provide the necessary
cryptographic primitives ("DESede/CBC/Nopadding" Cipher,
"ISO9797Alg3Mac" Mac).| Method Detail |
|---|
public long getSendSequenceCounter()
public CommandAPDU wrap(CommandAPDU commandAPDU)
capdu of a command apdu.
As a side effect, this method increments the internal send
sequence counter maintained by this wrapper.
wrap in interface APDUWrappercommandAPDU - buffer containing the command apdu.
public ResponseAPDU unwrap(ResponseAPDU responseAPDU,
int len)
rapdu of a response apdu.
unwrap in interface APDUWrapperresponseAPDU - buffer containing the response apdu.len - length of the actual response apdu.
|
JMRTD 0.4.6 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||