Launching a new BIN
A BIN (bank identification number, the first 6–8 digits of the card number) identifies an issuer’s card product. Every time a new one goes live, the processor runs the whole course in miniature: generate keys, exchange them across zones, configure, test.
1. The cast
| Party | Role | Shares with the processor |
|---|---|---|
| Card network (Visa, Mastercard) | Routes authorisations; may authorise on your behalf (STIP) | ZMK/ZCMK (paper ceremony), then PIN keys, and CVK / MK-AC if stand-in services are on |
| Card bureau (personalisation) | Manufactures cards, writes chip keys, prints CVV2, mails PINs | Its own ZMK; then MK-AC, MK-SMI, MK-SMC, MK-IDN/CVC3, CVK, PIN-mailer key |
| HSM / key custodian | Holds every key; may be your own HSM or a hosted one | Everything, under its master key |
2. Why “one BIN → one key set”
Each BIN gets its own IMKs and CVK (Card Verification Key). If a key set is ever compromised, only that BIN’s cards are at risk and need reissuing; the rest of the portfolio is untouched. Configuration then needs a mapping BIN → key set, so that when an authorisation arrives, the processor knows which (encrypted) keys to send to the HSM (Hardware Security Module).
3. The process
- Zones in place? ZMKs with the network and with the bureau usually exist already (ceremonies happen once per partner, not per BIN).
- Generate the key set in the HSM: MK-AC (Master Key for Application Cryptograms), MK-SMI (Master Key for Secure Messaging Integrity), MK-SMC (+ IDN/CVC3), CVK. Record each KCV (Key Check Value).
- Export each key as a TR-31 (ANSI X9 Technical Report 31, the key block format) block under the partner’s ZMK (Zone Master Key): one export for the bureau, one for the network if needed. Same keys, different wrappings (module 3, “same key, different hex”).
- Exchange KCVs with each partner; they import and confirm.
- Store the keys for your own use — encrypted under your HSM’s master key, or as HSM key references — in your secrets store, and add the BIN → key mapping to config.
- Test: generate and verify a CVV2 (Card Verification Value 2, the printed code) for a test card; verify an ARQC (Authorization Request Cryptogram) from a test card or test tool; run the network’s certification scripts.
- Go live, and document KCVs and custody in the key inventory (PCI requires one).
4. Puzzles you’ll meet
“Why are there two sets of keys?”
Possible answers, in the order to check them: (a) same keys under two different wrappings (for two partners, or for your HSM and for a partner) — KCVs match; (b) two products or brands (e.g. a Visa and a Mastercard range) — KCVs differ; (c) test vs production; (d) old and new keys during a rotation. Only the KCVs tell (a) from the rest.
“The bureau says our KCV is wrong”
Check, in order: same key (compare against your HSM’s KCV, not a spreadsheet); same KCV method (3DES (Triple DES) zeros vs AES (Advanced Encryption Standard) CMAC (Cipher-based MAC); 6 vs 4 digits); the right ZMK (theirs vs another partner’s); the key block format they expect (TR-31 vs a vendor format like AKB).
Exercises
Do you need a new key ceremony with the card bureau for every new BIN?
- Yes
- No, usually only once per partner (and on ZMK rotation)
Which key does the card network typically not need?
- The zone PIN (Personal Identification Number) key (ZPK)
- MK-SMC (secure messaging confidentiality)
- The CVK, if stand-in processing is enabled
Hint
Decrypt both with their own ZMKs, compare KCVs.The bureau imported your MK-AC and reports KCV 8A1B; your letter says 8A1B2C. Problem?
- Probably not: they display a 2-byte KCV, you a 3-byte one — the prefixes match
- Yes, different keys
Final boss. You are the processor. Go from paper components to a verified chip transaction.