beautypg.com

Reader encryption status, Encrypted track data – MagTek Bluetooth MagneSafe V5 Swipe Reader User Manual

Page 25

background image

Section 5. Communications

17

Reader Encryption Status

This two byte Binary field contains the Encryption Status. The Reader Encryption Status is sent
in big endian byte order. Byte 1 is the least significant byte. Byte 1 LSB is status bit 0. Byte 2
MSB is status bit 15. The Reader Encryption status is defined as follows:

Bit 0

= DUKPT Keys exhausted

Bit 1

= Initial DUKPT key Injected

Bit 2

= Encryption Enabled

Bit 3

= Authentication Required

Bit 4

= Timed Out waiting for user to swipe card

Bits 5–7

= Unassigned (always set to Zero)

Bit 8

= Encryption Counter Expired

Bits 9–15

= Unassigned (always set to Zero)

Notes:

1. Encryption will only be performed when Encryption Enabled and Initial DUKPT key

Injected are set. Otherwise, data that are normally encrypted are sent in the clear in
ASCII HEX format; the DUKPT Serial Number/counter will not be sent.

2. When DUKPT Keys Exhausted is set, the reader will no longer read cards and after a

card swipe, the reader response will be sent as follows:
[P30]
[P31]
[P35] [Reader Encryption Status]
[P35]
[P35]
[P35]
[P35]
[P35]
[P35] [Device serial number]
[P35] [Encrypted Session ID]
[P35] [DUKPT serial number/counter]
[P35] [Encryption Counter] (optional, off by default)
[P35] [Clear Text CRC]
[P35] [Encrypted CRC]
[P35] [Format Code]
[P34]


Encrypted Track Data

If decodable track data exists for a given track, it is located in the Track x Encrypted Data field
that corresponds to the track number. The length of each Encrypted Data field is fixed at 112
bytes, but the length of valid data in each field is determined by the corresponding Encrypted
Data Length
field that corresponds to the track number. Data located in positions greater than
the encrypted track data length field indicates are undefined and should be ignored. The HID
specification requires that reports be fixed in size, but the number of bytes encoded on a card
may vary. Therefore, the Input Report always contains the maximum amount of bytes that can
be encoded on the card and the number of valid bytes in each track is indicated by the Encrypted
Data Length
field.