Skip to content

Introduction

a7pay is a set of open-source EMV kernels and payment terminal building blocks, in Rust, written directly from the published specifications:

  • EMV Level 2: the contactless Entry Point and kernels (Books A, B, C-2 to C-8), with the contact kernel next.
  • Terminal and host protocols: the nexo standards a terminal speaks to its acquirer, its terminal manager and its sale system, and the nexo FAST payment application.
  • Platform contracts: four traits (reader, cryptography, security module, PIN pad) that are the only way the protocol code reaches a device.
  • Test platform: simulated cards and hosts on the public formats of the EMVCo Level 3 Testing Framework.

These pages explain each part for readers who know payments without being EMV specialists.

If you are new to EMV, read the first three pages in order: they explain what a payment terminal does and how a7pay is put together. The others go into each part.

Page What it explains
Glossary The EMV and payment terms the other pages use, in plain words
Architecture What a payment terminal does, the layers a7pay models, how one payment flows through them
Building Choosing what goes into a build (a terminal’s firmware, a test bench), depending on a7pay, running the tests
Platform The four interfaces a device implements (card reader, cryptography, security module, PIN pad), and the software ones for tests
Entry Point The part of the reader that finds the card’s payment application and hands over to the right kernel
Kernels The kernels a7pay implements, what each one does, their optional and scheme-specific behaviours
nexo The nexo standards a terminal speaks to its acquirer, its terminal manager and its cash register, and the nexo FAST payment application
Test environment A virtual terminal, acquirer, terminal manager and cash register talking to each other, to try a7pay out
Level 3 test platform Simulated cards and hosts on EMVCo’s Level 3 testing formats
Level 2 test suites How the kernels are checked against the schemes’ certification test suites
Level 2 test agent The application a device runs for its Level 2 certification, and the protocol a lab’s tools drive it with
Android reference device An Android phone as a contactless reader ready for a Level 2 lab: the agent in an Android application

With Rust installed, clone the repository and run:

cargo test --workspace --all-features

then run a payment through the virtual terminal, acquirer and TMS: see Try it out.