Our Online Store have the new products: RFID antenna board. Currently it can work with JC10M24R and JCOP4 card chips.
Compared with normal cards, the antenna board module has a smaller size and fixed holes, which is easy to integrate in the IOT(Internet Of Things) project.

The APDU test script of OpenEMV

The OpenEMV is a Java Card implementation of the EMV standard.

Moderator: Ellisun

User avatar
Posts: 50
Joined: Wed May 20, 2015 3:47 am
Points :472

The APDU test script of OpenEMV

Post by Ellisun » Fri Sep 18, 2015 10:31 pm

Code: Select all

//Select Applet, return File Control Information (FCI) Proprietary Template, it contains Dedicated File(DF), File Control Information and Application Tag.
//Generates an 8 byte random number .

//READ RECORD Command: '00B2' + Record number + Reference control parameter. (See Book 3, Section 6.5.11)
//Get the record of SFI 1, Record 1,It contains  Primary account number, Bank identifier code, Cardholder Verification Method (CVM) List and other fields.
//Get the Read record message template, record 2, It contains Certification Authority Public Key Index, Issuer Public Key Certificate, Issuer Public Key Remainder and Issuer Public Key Exponent.
//Get the Read record message template, record 3, It contains ICC Public Key Certificate, ICC Public Key Exponent, ICC Public Key Remainder and Dynamic Data Authentication Data Object List (DDOL).

//GET PROCESSING OPTIONS(GPO) Command: 80A80000 + Lc + PDOL related data + 00,(See Book 3, Section 6.5.8)
//In this applet, PDOL is not checked,The response message is a primitive data object with tag equal to '80'.the format is:
//80 + Length + AIP(Application Interchange Profile) + AFL(Application File Locator)

//GET DATA command: in EMV Specification, the value of P1P2 will be '9F36', '9F13', '9F17', or '9F4F'(Log Format) (See Book 3, Section 6.5.7)
//Get the data of ATC(Application Transaction Counter, tag '9F36')),
//Get the data of PIN Try Counter
//Get the data of Last Online ATC Register(tag '9F13')

//GENERATE AC command: It sends transaction-related data to the ICC, which computes and returns a cryptogram.in this applet of generateFirstAC only supporting request TC and ARQC.(See Book 3, Section 6.5.5)
//request TC

//Compute the second AC response APDU using Format 1.

  1. This SCR script is already tested successfully in IFD A40CR Card and R502 Reader.
  2. You can also download the attachment, and use pyApduTool to upload CAP file and send this SCR script.
You do not have the required permissions to view the files attached to this post. Please login first.

Posts: 5
Joined: Thu Aug 13, 2015 3:56 am
Points :2

Re: The APDU test script of OpenEMV

Post by monter001 » Wed Dec 02, 2015 2:32 am

A good summary of the APDU commands. And note the comments in detail for each APDU command.

Posts: 44
Joined: Thu Apr 06, 2017 8:01 am
Points :460

Re: The APDU test script of OpenEMV

Post by deepanshsinghal » Fri May 26, 2017 8:53 am

But the main problem in OpenEMV project is "Session Key" generation is incorrect and and mac also is not generating correct.... everyone need to work on that. But it's good to start from OpenEMV.

Post Reply Previous topicNext topic

Who is online

Users browsing this forum: No registered users and 1 guest

JavaCard OS : Disclaimer