ACR1255U-J1 – Reference Manual
Version V1.01
www.acs.com.hk
Page 42 of 73
6.4.2.
Authentication for MIFARE® Classic (1K/4K)
This command uses the keys stored in the reader to do authentication with the MIFARE Classic
(1K/4K) card (PICC). Two types of authentication keys are used: TYPE_A and TYPE_B.
Load Authentication Keys APDU Format (6 bytes) [Obsolete]
Command
Class
INS
P1
P2
P3
Data In
Authentication
FFh
88h
00h
Block
Number
Key Type
Key Number
Load Authentication Keys APDU Format (10 bytes)
Command
Class
INS
P1
P2
Lc
Data In
Authentication
FFh
86h
00h
00h
05h
Authenticate Data Bytes
Authenticate Data Bytes (5 bytes)
Byte1
Byte 2
Byte 3
Byte 4
Byte 5
Version 01h
00h
Block Number
Key Type
Key Number
Where:
Block Number
1 byte. The memory block to be authenticated.
For MIFARE Classic 1K card, it has a total of 16 sectors and each sector
consists of four consecutive blocks (e.g., Sector 00h consists of blocks
{00h, 01h, 02h and 03h}; sector 01h consists of blocks {04h, 05h, 06h
and 07h}; the last sector 0Fh consists of blocks {3Ch, 3Dh, 3Eh and
3Fh}. Once the authentication is done successfully, there is no need to
do the authentication again provided that the blocks to be accessed
belong to the same sector. Please refer to the MIFARE Classic (1K/4K)
specification for more details.
Note: Once the block is authenticated successfully, all the blocks
belonging to the same sector are accessible.
Key Type
1 byte.
60h = Key is used as a TYPE A key for authentication.
61h = Key is used as a TYPE B key for authentication.
Key Number
1 byte.
00 ~ 01h = Volatile memory for storing keys. The keys will disappear
when the reader is disconnected from the computer. Two volatile keys
are provided. The volatile key can be used as a session key for different
sessions.
Load Authentication Keys Response Format (2 bytes)
Response
Data Out
Result
SW1
SW2