Internal authenticate apdu – MagTek IntelliStripe65 99875161 User Manual
Page 107

Appendix B. Memory Card Support
101
Counter Highest Address properties, the command will not be processed.
This command writes one bit of the addressed byte from 1 to 0 (if there are any 1 bits available)
under control of the Erasure Mask. If a bit was actually written to 0 in the first step, the byte at
the next address on the card is erased.
The Erasure Mask is formulated to indicate one or more bits that can be written to zero to initiate
the erasure. Erasure will only be initiated if at least one zero bit in the Erasure Mask corresponds
to a one bit on the card. The first correspondence will initiate erasure and subsequent
correspondences will be written to zero until the entire Erasure Mask is processed.
The GAM326-BitOrder property dictates the order of bit processing.
If there is a need to erase multiple bytes of the Counter, multiple Erase Counter commands must
be sent in the proper order. Determining the order is the user’s responsibility.
Command APDU:
CLA
INS
P1
P2
Lc
Data
D0
0A
xx
Adr
01
Erasure Mask
CLA is always D0
INS is always 0A
P1 is ignored
P2 is the address where the erase will occur
Lc must be 01
Data contains one byte giving the Erasure Mask.
Response APDU:
SW1
SW2
Possible SW1/SW2 combinations:
SW1/SW2
Meaning
9000
Normal completion, no errors
6300
No bits to write, couldn’t erase
6700
Lc gives incorrect length
6B00
P2 is incorrect
Internal Authenticate APDU
The Internal Authenticate is used to authenticate the card to the hosting terminal.
If the Internal Authenticate is performed with CBC enabled, the CBC mode remains in effect
until the card is powered down.
The specified address is a bit address. It specifies the address of the bit where a Dummy Write is
performed to start the Authentication operation. For more details, see the Gemplus
documentation.