Tech, ExplainedSemiconductors and devices
Part

Secure element

The locked chip inside your contactless card.

INSIDE: MICROCONTROLLER (MCU)HOW IT WORKS · A ₹460 TAP AT A PHARMACY IN GUWAHATIThe terminal's radiofield powers thecard's chipThe terminal sendsthe amount, the dateand a random numberThe chip combinesthem with its counter(now 214) and itshidden key into an8-byte cryptogramYour bank repeats thecalculation with itscopy of the key: thecodes matchApproved in abouttwo seconds, withno PIN because ₹460is below ₹5,000ALSO TALKS TOPOS terminal↗ IN-STORE PAYMENTSCard network↗ IN-STORE PAYMENTSHardware root of trust↗ DATA CENTRESINSIDE: MICROCONTROLLER (MCU)HOW IT WORKS · A ₹460 TAPAT A PHARMACY IN GUWAHATIThe terminal'sradio field powersthe card's chipThe terminal sends theamount, the date and arandom numberThe chip combines themwith its counter (now214) and its hidden keyinto an 8-byte cryptogramYour bank repeatsthe calculationwith its copy of thekey: the codes matchApproved in abouttwo seconds, withno PIN because ₹460is below ₹5,000ALSO TALKS TOPOS terminal↗ IN-STORE PAYMENTSCard network↗ IN-STORE PAYMENTSHardware root of trust↗ DATA CENTRESINSIDE: MICROCONTROLLER (MCU) · A ₹460 TAP AT APHARMACY IN GUWAHATIThe terminal's radio field powers thecard's chip↓The terminal sends the amount, the dateand a random number↓The chip combines them with its counter(now 214) and its hidden key into an8-byte cryptogram↓Your bank repeats the calculation withits copy of the key: the codes match↓Approved in about two seconds, with noPIN because ₹460 is below ₹5,000ALSO TALKS TOPOS terminal↗ IN-STORE PAYMENTSCard network↗ IN-STORE PAYMENTSHardware root of trust↗ DATA CENTRES
A ₹460 tap at a pharmacy in Guwahati: the card's chip receives the payment details, calculates a cryptogram with its hidden key, and the bank repeats the calculation to approve the payment.
opens a page inside this one a page in the same scene a page in another scene a concept page a label only, with no page

A secure element is a tiny, locked-down microcontroller that stores secret keys and uses them without ever revealing them. It is the chip inside a contactless debit or credit card, a SIM card and an e-passport, and many phones contain one too. It is a microcontroller, with a processor, memory and a program. But it is built to resist anyone who tries to read its secrets, even with laboratory equipment.

How does it prove a card is real? When the bank prepares the card, it stores a secret key inside the chip. A key is a long secret number. At each payment, the chip uses the key to calculate a cryptogram, a short code made from the payment details, using the mathematics of encryption. The bank holds its own copy of the key, so it can repeat the calculation and check that the codes match. The key itself never leaves the chip. The chip also keeps a counter that rises by one at every payment. So each cryptogram is different, and a code copied from one payment cannot be used again.

What makes it secure? Its memory is encrypted, and a metal mesh covers its circuits. Sensors detect probing, unusual light, voltage or temperature, and the chip erases its keys if it is attacked. It also varies its timing and power use, so that an attacker cannot work out the key by measuring how much power the chip draws. Secure elements are tested and certified by independent laboratories before banks may use them.

Say you buy medicines for ₹460 at a pharmacy in Guwahati and tap your contactless RuPay debit card on the POS terminal. The card has no battery. The terminal's radio field powers the chip for a fraction of a second. The terminal sends the chip the amount, the date and a random number. The chip combines these with its counter, which now stands at 214, and its secret key, and calculates an 8-byte cryptogram. The terminal sends the cryptogram and the card details through the acquiring bank and the card network to your bank's card issuing platform. Your bank repeats the calculation with its copy of the key. The codes match, so it approves the payment. The card's part takes under half a second, and approval takes about two seconds in all. No PIN is needed, because the amount is below the RBI's ₹5,000 limit for contactless payments without a PIN.

The same idea protects other devices. A phone that pays with a tap stores a card token in its own secure element or in a protected area of its processor. Laptops and servers have a hardware root of trust, a security chip that checks the firmware before anything else starts. The difference is the job: a secure element answers questions from an outside reader, while a root of trust checks the machine it sits in.

Tech, Explained is a part of ingrid.fyi. Every page explains one piece of technology in plain words.