beautypg.com

28 report 0x31 – set ksn encrypted data, Report 0x31 – set ksn encrypted data, 3 - command set – MagTek DynaPro Mini Programmer's99875629 User Manual

Page 53

background image

3 - Command Set

DynaPro Mini| PIN Encryption Device | Programmer’s Reference (Commands)


Page 53

Bit

7

6

5

4

3

2

1

0

Byte 2..11

Data block:
Byte 2 – Byte 11 contain the KSN

Byte 12..19 Device Serial Number

Byte 20..23 Padding

Byte 24..27 CBC-MAC

3.4.28 Report 0x31 – Set KSN Encrypted Data

Before using this command, the host must have already used Report 0x30 – Set / Get KSN to retrieve
the MSR dukpt KSN from the device. Then the host must use Report 0x10 – Send Big Block Data to
Device
to send encrypted PAN data to the device, in the following format:

AAAA /* 2-byte MSB message length excluding padding and CBC-MAC */
F9 /* container for MAC structure and generic data */

DFDF54(MAC KSN)

DFDF55(MAC Encryption Type)

DFDF25(IFD Serial Number)

FA/* container for generic data */

DFDF44 (Encrypted PAN data)

(Buffer if any to be a multiple of 8 bytes)

CBC-MAC (4 bytes, use MAC variant of MSR dukpt key)


The host can then use this command to process data in the big block. The device decrypts and displays
the data until the display timeout expires.

This feature is used for the Token Reversal Function.

The value of DFDF44 is always encrypted under the data variant of the MSR dukpt key.

Responses:

OK, ACKSTS = 0

Bad CBC-MAC ACKSTS = 0x82

Wrong Serial Number, ACKSTS = 0x82

Table 3-43 – Usage Table for Report 0x31

Bit

7

6

5

4

3

2

1

0

Byte 0

0x31

Byte 1

Display Time in seconds, (1 – 255; 0 = 256 seconds)