FAQ Database Discussion Community


I got '67 00' error when I create value file for DESFire

android,mifare,apdu,contactless-smartcard
I'm working with DESFire cards and I now want create a value file in my application (app has ID 00 00 01). I successfully selected my app with the given ID and then send my command for creating the value file to the isodep.transceive method. My command is here: byte[]...

NDEF vs APDU NFC Android

android,nfc,apdu,ndef,contactless-smartcard
Can you tell me please what is the difference between NDEF (NFC Data Exchange Format) and APDU (Application Protocol Data Unit). I have developed an Android application that reads NDEF messages, and I want to know if it can work for APDU data too....

Unable to construct VERIFY_PIN_DIRECT control command

smartcard,apdu,smartcard-reader,openpgp,pcsc
I'm writing a JAVA-app to access my OpenPGP-Card V2.0. The card terminal im using is a "REINER SCT cyberJack RFID standard" which only supports PC/SC under OSX, and now I want to implement the PC/SC 2.0-command "VERIFY_PIN_DIRECT". I tried the following control sequence, the bytes after the | are the...

APDU MIFARE Classic 4K read value at specific sector/block

nfc,smartcard,mifare,apdu,smartcard-reader
I'm trying to read some data from my MiFare Classic 4K smartcard. I already know the exact sector/block location of the data (because of a dump via Android), but I don't know how to show it in SpringCard Prox'N'Roll. I know how to access my card and I did a...

Two OwnerPIN object in Java Card

security,smartcard,javacard,apdu,pin-code
I am working on a Java Card application where our requirement is to keep some static data and balance in the card. For security I was thinking to make 2 object of OwnerPIN. One object is for terminal authentication (i.e. the terminal needs to send 8 bytes of data to...

AID for HID readers

android,nfc,apdu,hce,contactless-smartcard
If I want my android phone to emulate a physical card to the following reader: http://www.hidglobal.com/products/readers/iclass/rw100 Which AID would I have to use? I was following this example: https://developer.android.com/guide/topics/connectivity/nfc/hce.html#HceServices But when debugging, my code never reaches the public byte[] processCommandApdu(byte[] commandApdu, Bundle extras) { method. Seems the Android device still...

Recovering an ECPublicKey from Java to JavaCard

java,cryptography,javacard,apdu,elliptic-curve
This question is related to the one I asked yesterday : Recovering an ECPublicKey from JavaCard to Java I have the same problem but in the opposite way : After sending the public key from my card to my computer (the point is represented as an octet string in uncompressed...

ADPU Service in iOS

ios,nfc,smartcard,apdu,contactless-smartcard
I'm looking for an NFC solution for iOS similar to HostApduService for Android. Can someone tell me how can I exchange APDU commands in iOS. Thank you....

ISO7816 - Odd INS codes?

smartcard,javacard,apdu
I found these mysterious lines in ISO 7816, (http://www.cardwerk.com/smartcards/smartcard_standard_ISO7816-4_5_basic_organizations.aspx#chap5_4): 5.4.2 Instruction byte The instruction byte INS of a command shall be coded to allow transmission with any of the protocols defined in part 3 of ISO/IEC 7816. Table 10 shows the INS codes that are consequently invalid. Table 10 -...

Recovering an ECPublicKey from JavaCard to Java

java,bouncycastle,javacard,apdu,elliptic-curve
I am trying to implement ECDH between a terminal (simulated by my computer) and a smart card (Java Card). I fixed the elliptic curve that I want to use, and on the card side I have the following code to run the first part of the protocol : ECPublicKey pubKey...

Smart Card Reader T0 T1 communication on APDU level

smartcard,apdu,smartcard-reader
I am struggle to understand what protocol I have to use to communicate with the card T0 or T1? So, correct me if I am wrong, but the reader actually decides by itself what protocol to use to communicate with the card if the card supports both. So my logic...

I got 0x1E error (INTEGRITY_ERROR) while change DESFire master key.What are my mistakes?And How can I resolve?

java,apdu,crc16,contactless-smartcard
Whole update1: see question again. I recently am working with DESFire cards .I now decide to change defult master key of PICC. (I already could authenticate with master key all 8 byte 0x00 successfully) 1- Defult master key is 8 byte of zero.It is 00 00 00 00 00 00...

Trying Java Card Application On real smart card

javacard,apdu
I will write an application for smart card with using Java Card Framework.When I finished my application I want to set up to a real smart card and try it.Which equipment I must have?How can I run my codes on a real smart card?I have to provide a connector between...

Howto list files on a smartcard with pyscard

python,smartcard,apdu,smartcard-reader,pyscard
I have to read out a file from a smartcard. The card is written by a digital tachograph that monitors vehicle movements. I could connect to the smartcard reader with psycard (http://pyscard.sourceforge.net/user-guide.html) but then I don't know how to list files on the card and how to download them. I...

Sending signature data in response APDU - Java Card

digital-signature,smartcard,javacard,apdu,ecdsa
I would like to sign some data (the MESSAGE byte array) on my Java Card and then return the signature in a response APDU. My code works fine (or at least I think it does and it returns 9000) without the line apdu.sendBytes(BAS, sSignLen), but when I uncomment it I...

How to send a data array to my Applet and manipulation it by Applet and return new data in response apdu?

arrays,applet,javacard,apdu
I want to send a random byte array including for example 24 elements to my JavaCard applet and then my applet is supposed to change that array using a specific method. For example that method XOR each elements with 0x05 and returns the result array in APDU response. To aim...

Cardholder name not included when reading EMV card

nfc,apdu,contactless-smartcard,emv,tlv
I've successfully been able to retrieve the card number and expiry date from a contactless debit/credit card. However, the cardholder name is not being returned in the READ RECORD command response. Am I missing a something? - Select Application # IN_DATA_EXCHANGE >> D4 40 01 00 A4 04 00 07...

I got 0x9E parameter error while Credit value file on DESFire card

android,nfc,mifare,apdu,contactless-smartcard
I now work with value files on DESFire cards. I created a value file in my DESFire card with the following command: byte[] cmdCreateValueFile = new byte[]{ //cmd (byte)0xCC, //file no (byte)0x01, //com.sett. (byte)0x00 , //access rights (byte)0x44 , (byte)0x44, //lower limit (byte)0x00 ,(byte)0x00 ,(byte)0x00 ,(byte)0x00 , //upper limit (byte)0x00...