I have SPR332 pinpad reader and i have to write programm on java that verify pin of bank cards.
So this is my PINverifyStructure :
bTimeOut = 0х00
bTimeOut2 = 0х00
bmFormatString = 0x82
bmPINBlockString = 0x47
bmPINLengthFormat = 0x04
wPINMaxExtraDigitMax = 0x0c
wPINMaxExtraDigitMin = 0x00
bEntryValidationCondition = 0x02
bNumberMessage = 0x01
wLangId = 0x09 0x04
bMsgIndex = 0x00
bTeoPrologue = 0x00 0x00 0x00
ulDataLength = apduLength 0x00 0x00 0x00
Verify APDU command is :
CLA = 0x00
INS = 0x20
P1 = 0x00
P2 = 0x00
LC = 0x08
0x20
0xff
0xff
0xff
0xff
0xff
0xff
0xff
After this i enter pin on pinpad, then i receive APDU response 6a86. In APDU responses specification it means "Incorrect P1 or P2 parameter."
Please, help, what's wrong with my command?
I changed P2 to 0x01 , response is the same 6a86
I've finally found why response was 6a81.
It was because i have EMV card, so VERIFY command should be called in a specific order (after SELECT FILE, GET PROCESSING OPTIONS, READ RECORD, GET DATA).
Now i have 9000. Thx all