ARQC verifier and calculator
Shows each derivation step and tests common input variations when an ARQC does not match.
- Runs in your browser
- No sign-up
Input
Result
The data the MAC covers
Labelled in the EMV Book 2 recommended order, which Visa CVN 10 and 18 follow; check other versions against their own layout. The MAC runs over 4 blocks of 8 bytes:
Derivation trace (7 steps)
Every intermediate value is shown so you can find which input is wrong. Runs in your browser. Test keys only.
Cryptogram still not matching after every variation? IDNTEQ’s EMV team can find the cause. EMV transaction troubleshooting
About this tool
Runs in your browser. This page loads no analytics or third-party scripts and does not send what you type.
Verify or generate an ARQC with the derivation trace visible: IMK → UDK → session key, KCVs at each stage, the assembled and padded data block, and the computed cryptogram. On a mismatch the tool re-runs the computation with common mistakes and reports any variant that matches.
Derivation trace
Debugging a cryptogram mismatch means finding which input is wrong, so the tool shows every intermediate value: the UDK derived from the IMK (EMV master key derivation), the session key (the EMV Common Session Key, or none where the card key is used directly), the transaction data, the padded data block (ISO 9797-1 Method 2, or Method 1 zero padding) and the Retail-MAC output.
Two profiles are preset and reproduce published examples: Visa CVN 18 (Option B card key, EMV Common Session Key, Method 2 padding, ARPC method 2; AWS ARQC example and the pyemv VisaCVN18 example, ARPC 76503F48; CVN 22 uses the same derivation with different transaction data) and Visa CVN 10 (Option A card key used directly, zero padding, ARPC method 1; AWS example). Option B only differs from Option A for PANs longer than 16 digits. Mastercard CVN 14 and 15 also use the EMV Common Session Key, so they can be computed with that setting and the transaction data the Mastercard profile defines; there is no Mastercard preset and no Mastercard example has been checked. Mastercard CVN 12 and 13 use a Mastercard-specific session key derivation that includes the unpredictable number; it is not supported.
Checks on a mismatch
When your expected ARQC does not match, the tool re-runs the computation with a set of common mistakes (the other session-key method, the other padding method, already-padded data, byte-swapped ATC) and reports any variant that reproduces the expected value. A matching variant points to a likely cause; it does not prove it.
If no variant matches, check the data-element order, the key value and the PAN/PSN against the profile and the test data.
Published examples and input conventions
Load a published example to see the published value next to the tool’s result. Transaction data can be entered raw (the tool pads it) or already padded (used as is). The ARPC is computed over the ARQC to verify when one is given, as the issuer would answer the ARQC it received.
Spec references
- EMV 4.4 Book 2 §8.1 (Application Cryptogram)
- EMV Book 2 Annex A1.3 (Session Key derivation)
- EMV Book 2 Annex A1.4 (Option A / Option B)
- EMV Book 2 §8.2 (ARPC methods 1 and 2)
- EMV Book 3 Annex C10 (Card Status Update)
- ISO 9797-1 (MAC Algorithm 3)
Verified against
- Specifications
- EMV 4.4 Book 2 §8.1 and Annex A1.3 (Application Cryptogram, Common Session Key)
- EMV 4.4 Book 2 Annex A1.4 (card key derivation, Option A and Option B)
- EMV 4.4 Book 2 §8.2 (ARPC methods 1 and 2)
- ISO/IEC 9797-1 MAC algorithm 3, padding methods 1 and 2
- Published examples in the tests
- Other checks in the tests
- Option A card key and common session key against an OpenSSL TDES construction
- Mismatch diagnosis: wrong padding, wrong session-key method, swapped ATC, already-padded data
- Inputs
- IMK or UDK (16 bytes), PAN 1–19 digits, PSN, ATC, transaction data raw or already padded, optional ARQC and ARC/CSU.
- Not covered
- Mastercard CVN 12/13 session keys are not supported; no Mastercard example has been checked. Transaction data must be assembled in the order the CVN requires.
- Last reviewed