|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Object | +--APDU
Class implementing support for command and response APDUs
Defined in apdu.js
Field Summary | |
Object |
cdata
|
Object |
cla
|
Object |
ins
|
Object |
ne
|
Object |
p1
|
Object |
p2
|
Object |
rapdu
|
Object |
SW
|
<static> Object |
INS_ACTIVATE
|
<static> Object |
INS_CHANGE_REFERENCE_DATA
|
<static> Object |
INS_COMPUTE_DIGITAL_SIGN
|
<static> Object |
INS_DEACTIVATE
|
<static> Object |
INS_EXTERNAL_AUTHENTICATE
|
<static> Object |
INS_GENERAL_AUTHENTICATE
|
<static> Object |
INS_GENERATE_KEY_PAIR
|
<static> Object |
INS_GET_CHALLENGE
|
<static> Object |
INS_MANAGE_SE
|
<static> Object |
INS_PSO
|
<static> Object |
INS_READ_BINARY
|
<static> Object |
INS_READ_RECORD
|
<static> Object |
INS_READBINARY
|
<static> Object |
INS_RESET_RETRY_COUNTER
|
<static> Object |
INS_SELECT
|
<static> Object |
INS_TERMINATE
|
<static> Object |
INS_UPDATE_BINARY
|
<static> Object |
INS_VERIFY
|
<static> Object |
INS_VERIFY_CERTIFICATE
|
<static> Object |
SW_ACNOTSATISFIED
|
<static> Object |
SW_AUTHMETHLOCKED
|
<static> Object |
SW_CHAINNOTSUPPORTED
|
<static> Object |
SW_CLANOTSUPPORTED
|
<static> Object |
SW_COMINCOMPATIBLE
|
<static> Object |
SW_COMNOTALLOWED
|
<static> Object |
SW_COMNOTALLOWNOEF
|
<static> Object |
SW_CONDOFUSENOTSAT
|
<static> Object |
SW_DATAINV
|
<static> Object |
SW_DFNAMEEXISTS
|
<static> Object |
SW_EOF
|
<static> Object |
SW_EXECERR
|
<static> Object |
SW_FILEEXISTS
|
<static> Object |
SW_FILENOTFOUND
|
<static> Object |
SW_FUNCNOTSUPPORTED
|
<static> Object |
SW_GENERALERROR
|
<static> Object |
SW_INCP1P2
|
<static> Object |
SW_INCSMDATAOBJECT
|
<static> Object |
SW_INVACC
|
<static> Object |
SW_INVCLA
|
<static> Object |
SW_INVDATA
|
<static> Object |
SW_INVFILE
|
<static> Object |
SW_INVFORMAT
|
<static> Object |
SW_INVINS
|
<static> Object |
SW_INVLC
|
<static> Object |
SW_INVLCTLV
|
<static> Object |
SW_INVLE
|
<static> Object |
SW_INVP1P2
|
<static> Object |
SW_INVPARA
|
<static> Object |
SW_LASTCMDEXPECTED
|
<static> Object |
SW_LCNOTSUPPORTED
|
<static> Object |
SW_MEMERR
|
<static> Object |
SW_MEMERRWRITE
|
<static> Object |
SW_NOAPPL
|
<static> Object |
SW_NOMORESTORAGE
|
<static> Object |
SW_OK
|
<static> Object |
SW_OKMOREDATA
|
<static> Object |
SW_OUTOFMEMORY
|
<static> Object |
SW_RDNOTFOUND
|
<static> Object |
SW_RECORDNOTFOUND
|
<static> Object |
SW_REFDATANOTUSABLE
|
<static> Object |
SW_SECSTATNOTSAT
|
<static> Object |
SW_SMNOTSUPPORTED
|
<static> Object |
SW_SMOBJMISSING
|
<static> Object |
SW_TIMEOUT
|
<static> Object |
SW_WARNING
|
<static> Object |
SW_WARNING0LEFT
|
<static> Object |
SW_WARNING1
|
<static> Object |
SW_WARNING1LEFT
|
<static> Object |
SW_WARNING2LEFT
|
<static> Object |
SW_WARNING3LEFT
|
<static> Object |
SW_WARNINGCOUNT
|
<static> Object |
SW_WARNINGNVCHG
|
<static> Object |
SW_WRONGLENGTH
|
Constructor Summary | |
APDU()
Create an APDU This constructor supports the signatures
|
Method Summary | |
void
|
fromByteString(<ByteString> bs)
Create an APDU object from the encoded form (Called internally) |
ByteString
|
getCData()
Gets the command data |
TLVList
|
getCDataAsTLVList()
Gets the command data as a list of TLV objects |
Number
|
getCLA()
Gets the class byte |
ByteString
|
getCommandAPDU()
Get encoded command APDU |
Number
|
getINS()
Gets the instruction byte |
Number
|
getNe()
Gets the number of expected bytes |
Number
|
getP1()
Gets the P1 byte |
Number
|
getP2()
Gets the P2 byte |
ByteString
|
getRData()
Get the response data |
ByteString
|
getResponseAPDU()
Get encoded response APDU |
SecureChannel
|
getSecureChannel()
Return the secure channel, if any |
Number
|
getSW()
Get the status word |
boolean
|
hasCData()
Check if APDU has command data |
boolean
|
hasLe()
Check if APDU has Le field |
boolean
|
hasRData()
Check if APDU has response data |
boolean
|
hasSecureChannel()
Test if a secure channel is defined for this APDU |
boolean
|
isAuthenticatedHeader()
Test if command is send using secure messaging |
boolean
|
isChained()
Test if command chaining is indicated |
boolean
|
isISO()
Test if command is an ISO command |
boolean
|
isSecureMessaging()
Test if command is send using secure messaging |
void
|
setCData(<ByteString> cdata)
Set the command data |
void
|
setRData(<ByteString> data)
Sets the response data field for the response APDU |
void
|
setSecureChannel(<SecureChannel> secureChannel)
Set secure channel object to be used in wrap and unwrap methods |
void
|
setSW(<Number> sw)
Sets the status word for the response ADPU |
Object
|
toString()
Return a human readable form of this object |
void
|
unwrap()
Unwrap APDU using secure channel |
void
|
wrap()
Wrap APDU using secure channel |
<static> void
|
test()
Simple unit test |
Field Detail |
Object cdata
Object cla
Object ins
Object ne
Object p1
Object p2
Object rapdu
Object SW
<static> Object INS_ACTIVATE
<static> Object INS_CHANGE_REFERENCE_DATA
<static> Object INS_COMPUTE_DIGITAL_SIGN
<static> Object INS_DEACTIVATE
<static> Object INS_EXTERNAL_AUTHENTICATE
<static> Object INS_GENERAL_AUTHENTICATE
<static> Object INS_GENERATE_KEY_PAIR
<static> Object INS_GET_CHALLENGE
<static> Object INS_MANAGE_SE
<static> Object INS_PSO
<static> Object INS_READ_BINARY
<static> Object INS_READ_RECORD
<static> Object INS_READBINARY
<static> Object INS_RESET_RETRY_COUNTER
<static> Object INS_SELECT
<static> Object INS_TERMINATE
<static> Object INS_UPDATE_BINARY
<static> Object INS_VERIFY
<static> Object INS_VERIFY_CERTIFICATE
<static> Object SW_ACNOTSATISFIED
<static> Object SW_AUTHMETHLOCKED
<static> Object SW_CHAINNOTSUPPORTED
<static> Object SW_CLANOTSUPPORTED
<static> Object SW_COMINCOMPATIBLE
<static> Object SW_COMNOTALLOWED
<static> Object SW_COMNOTALLOWNOEF
<static> Object SW_CONDOFUSENOTSAT
<static> Object SW_DATAINV
<static> Object SW_DFNAMEEXISTS
<static> Object SW_EOF
<static> Object SW_EXECERR
<static> Object SW_FILEEXISTS
<static> Object SW_FILENOTFOUND
<static> Object SW_FUNCNOTSUPPORTED
<static> Object SW_GENERALERROR
<static> Object SW_INCP1P2
<static> Object SW_INCSMDATAOBJECT
<static> Object SW_INVACC
<static> Object SW_INVCLA
<static> Object SW_INVDATA
<static> Object SW_INVFILE
<static> Object SW_INVFORMAT
<static> Object SW_INVINS
<static> Object SW_INVLC
<static> Object SW_INVLCTLV
<static> Object SW_INVLE
<static> Object SW_INVP1P2
<static> Object SW_INVPARA
<static> Object SW_LASTCMDEXPECTED
<static> Object SW_LCNOTSUPPORTED
<static> Object SW_MEMERR
<static> Object SW_MEMERRWRITE
<static> Object SW_NOAPPL
<static> Object SW_NOMORESTORAGE
<static> Object SW_OK
<static> Object SW_OKMOREDATA
<static> Object SW_OUTOFMEMORY
<static> Object SW_RDNOTFOUND
<static> Object SW_RECORDNOTFOUND
<static> Object SW_REFDATANOTUSABLE
<static> Object SW_SECSTATNOTSAT
<static> Object SW_SMNOTSUPPORTED
<static> Object SW_SMOBJMISSING
<static> Object SW_TIMEOUT
<static> Object SW_WARNING
<static> Object SW_WARNING0LEFT
<static> Object SW_WARNING1
<static> Object SW_WARNING1LEFT
<static> Object SW_WARNING2LEFT
<static> Object SW_WARNING3LEFT
<static> Object SW_WARNINGCOUNT
<static> Object SW_WARNINGNVCHG
<static> Object SW_WRONGLENGTH
Constructor Detail |
APDU()
This constructor supports the signatures
command
- the command APDU
cla
- the class byte
ins
- the instruction byte
p1
- the first parameter
p2
- the second parameter
data
- the data field (optional)
Ne
- the number of expected bytes (optional)
Method Detail |
void fromByteString(<ByteString> bs)
bs
-
ByteString getCData()
TLVList getCDataAsTLVList()
Number getCLA()
ByteString getCommandAPDU()
Number getINS()
Number getNe()
Number getP1()
Number getP2()
ByteString getRData()
ByteString getResponseAPDU()
SecureChannel getSecureChannel()
Number getSW()
boolean hasCData()
boolean hasLe()
boolean hasRData()
boolean hasSecureChannel()
boolean isAuthenticatedHeader()
boolean isChained()
boolean isISO()
boolean isSecureMessaging()
void setCData(<ByteString> cdata)
cdata
- the command data
void setRData(<ByteString> data)
data
- the response data field
void setSecureChannel(<SecureChannel> secureChannel)
secureChannel
- the channel
void setSW(<Number> sw)
sw
- the status word
Object toString()
void unwrap()
void wrap()
<static> void test()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |