User's Manual

PIN Pad 791 Programmer’s Manual (PCI POS-A) UDN PM0103-U Rev. 06
Section 9 – Online transaction messages with Master / Session keys 2015-04-20
Page231
Uniform Industrial Corp. Proprietary and Confidential Total 342 pages
Message Z66 Message Authentication Code (MAC) Request
Format: <STX>Z66[PktType][SeqNo][KeyId] <FS> [SessionKey] <FS> [SecKeyId]
<FS> [Message] <ETX> [LRC]
Message length: Variable 14 to 270 bytes.
Usage: This message is used to generate MAC codes according to algorithm specified in ANSI
X9.19 (ISO 9797-1). User can send ASCII strings or hexadecimal strings to PP791 by
Z66 message to generate its MAC. User can also separate a long message into
multiple Z66 messages with increasing sequence number to generate a MAC.
NOTE: Message Length: Onetime message can be up to 224 characters (equal to 112bytes
when send as hexadecimal string because 2 characters represents 1 bytes). Multiple
messages can have sequence number from 00 to 99, thus the maximum capacity of
Z66 message is 22400 characters (or 11200 bytes in binary mode).
Multiple messages: When using multiple messages, [KeyId] and [SessionKey] and
[SecKeyId] must be the same. [Message] must be the multiple of 8 characters (or 16
characters in binary mode). Or PP791 will generate a wrong MAC.
MAC algorithm: PP791 generate TDES MAC according to ISO9797-1 algorithm 3.
(Padding with 0. Initial vector = 0. Refer to Appendix A point 10 for detail algoritgm.)
Session Key: The value of session key relates to the usage of specified master keys.
Usage of 1
st
Key ID
Usage of 2
nd
Key ID
Value of session key MAC Key
“K0” N/A Non-zero Session key
“M3”
(mode G)
N/A Zero Master key specified by
[KeyId].
If specified key is mode ‘V’,
this is for MAC verification
and cannot used to generate
MAC for Z66 command.
“M1”
(mode G)
“M1” Zero Master key specified by
[KeyId] as left key, and
master key specified by
[SecKeyId] as right key.