Unable to generate correct application cryptogram


Unable to generate correct application cryptogram



I am successfully getting Generate Command response


[9F02 06 (Amount, authorized, numeric)]: 000000003000
[9F03 06 (Amount, other, numeric)]: 000000000000
[9F1A 02 (Terminal country code)]: 0826
[95 05 (Terminal verification results)]: 0000000000
[5F2A 02 (Transaction currency code)]: 0826
[9A 03 (Transaction date)]: 150724 (2015-05-28)
[9C 01 (Transaction type)]: 00
[9F37 04 (Unpredictable number)]: 12345678



And the command is


80 AE 4000 1D 000000003000 000000000000 0826 0000000000 0826 150724 00 12345678 00



With sucessful response


8012800008d2715ae1b83027db06020103a0b0009000

Cryptogram Information Data : 00
Application Transaction Counter : 0008
Application Cryptogram : d2715ae1b83027db
Issuer Application Data : 06020103a0b000



Everything is good, but whenever I perform transaction in the test environment I get



The Application Cryptogram was incorrect.



Any help would be appreciated.





You did not tell which card / card brand you are using. Because of this different "Key Derivation Methods", "Key Derivation Data" and "Transaction Data" should be used for cryptogram calculation. To be simple there are several ARQC/ARPC algorithms used in the world of payments. I hope you are talking about test card and your test environment know the correct UDK or Master Key (MK) to check Cryptogram.
– iso8583.info support
Jul 24 '15 at 17:22





@iso8583.infosupport I am using AMex card with test environment. But i am not using any key
– Wajahat Chaudhry
Jul 27 '15 at 5:37





Does test description specify the transaction date to be used? If yes, then why you have 9AF3 == 150724 and date in the comment (2015-05-28)?
– Serge
May 11 '16 at 23:21





1 Answer
1



First of all in your data sample "Transaction date" in packed YYMMDD format is not the same value as in human readable format (YYYY-MM-DD). Dates are different.



If you sent incorrect transaction data or transaction data not related to this ARQC you will fail Cryptogram validation at the host environment.



Because of using Amount 30.00 with Amex test cases, the card detected
as "AEIPS 20 TEST CARD" from Amex Global set.



Recalculation of ARQC using the "Transaction data" gave me the same
value as in your card response - 0x9F26 = "d2715ae1b83027db". So, it is
confirmed.



ARPC in this case will be "3784BAE0B266DF17".



Certified test environments or Amex Test System (ATS) itself can provide you the ARQC/ARPC recalculation details. Sure if test environment can validate your card brand.



Issue usually in the financial message and Transaction data inside which developers incorrectly packed for external test host validation. (As in your original request.)



Take full trace of transaction from card, thru terminal to host system and you will get where is data misplacement.





They are showing me recalculated cryptogram which is "2C 36 CA 56 E1 35 BB DC" against my cryptogram "d2715ae1b83027db". if i use their cryptogram they validate the request but i tried my best to generate same cryptogram same like them but fails. can you please suggest something
– Wajahat Chaudhry
Jul 28 '15 at 5:14






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Comments

Popular posts from this blog

paramiko-expect timeout is happening after executing the command

how to run turtle graphics in Colaboratory

Export result set on Dbeaver to CSV