contactless-smartcard

Desfire EV1 communication examples

烂漫一生 提交于 2019-12-08 22:48:21
问题 There are lots of questions about Desfire EV1 cards here on Stackoverflow. But if you search for some example data the only place where you will find a few bytes is in Ridrix Blog. But this is quite incomplete. A lot of people wrote their problems there while developing code for Desfire cards. But mostly when they solved their problem they were too lazy to post the solution. So you find many questions but very few answers with data examples. Even if you have the Desfire EV1 documentation (I

Host Card Emulation Android 4.4

我们两清 提交于 2019-12-08 19:14:28
Now that Android supports Card Emulation on the Nexus 5 with Android 4.4, is it likely that some apps may become available that allow me to effectively duplicate a smartcard (e.g. Smart Card that opens doors in my office) and use my phone in their place? Would be pretty handy. Cheers! No, this is not likely. Typically, copying/cloning arbitary cards using Android HCE is not possible. Many access control systems use the card ID (UID) to identify the card (or even to make an access control desicion!). With Android HCE, an app cannot set the emulated card ID. Many access control systems use cards

Is the Samsung Galaxy S4 compatible with CyanogenMod's smart card emulation (NFC)?

谁都会走 提交于 2019-12-08 12:04:15
问题 I have the Samsung Galaxy S4 and the SCM SDI010 card reader. My goal is to let the S4 emulate a smart card which then can be read by the card reader. I tried to apply the PKI applet example described here (installing CyanogenMod 10.2, starting se-emulator on the S4 and starting the se-pki-client on my Linux PC). But the connection establishment fails with either a "SCARD_W_UNRESPONSIVE_CARD" or "SCARD_W_UNPOWERED_CARD" exception on the reader side. Does anyone know if the NFC chip on the S4

Can I access a Prox card from within a web page?

醉酒当歌 提交于 2019-12-08 11:06:38
问题 I have an internal web based utility that we use to keep track of employee training. Currently, in order to indicate that training has been completed, the employee being trained has to input their employee number and a PIN. Then, the person conducting the training has to do the same. This utility runs on dedicated touch screen computers that run Chrome in kiosk mode. Everybody in the company already carries a Prox Card. I also have a 5025CL reader. Getting the information about which employee

Why I can't receive APDU buffer contents?

笑着哭i 提交于 2019-12-08 07:42:49
问题 I wrote the following program to return all the APDU buffer contents on reception of each APDU command: package testPack; import javacard.framework.APDU; import javacard.framework.Applet; import javacard.framework.ISOException; public class BufferReturner extends Applet { private BufferReturner() { } public static void install(byte bArray[], short bOffset, byte bLength) throws ISOException { new BufferReturner().register(); } public void process(APDU arg0) throws ISOException { if

Why I can't receive APDU buffer contents?

杀马特。学长 韩版系。学妹 提交于 2019-12-06 14:52:05
I wrote the following program to return all the APDU buffer contents on reception of each APDU command: package testPack; import javacard.framework.APDU; import javacard.framework.Applet; import javacard.framework.ISOException; public class BufferReturner extends Applet { private BufferReturner() { } public static void install(byte bArray[], short bOffset, byte bLength) throws ISOException { new BufferReturner().register(); } public void process(APDU arg0) throws ISOException { if(selectingApplet()){ return; } arg0.setOutgoingAndSend((short)0, (short)255); } } When I send commands though the

ACR1222L FF 82 Load Authentication Keys fails with 63 00 Operation Failed

a 夏天 提交于 2019-12-06 13:55:49
问题 I'm using ACR1222L NFC smartcard reader with Mifare Plus cards (Security Level 0 as of now; manufacturer default keys A and B). I tried a variety of commands to load authentication key into the reader: FF 82 00 00 06 FF FF FF FF FF FF FF 82 00 01 06 FF FF FF FF FF FF FF 82 20 00 06 FF FF FF FF FF FF FF 82 00 00 06 A0 A1 A2 A3 A4 A5 FF 82 00 00 06 D3 F7 D3 F7 D3 F7 ... and others ... All of them are returning the error status: 63 00 (Operation Failed) What could be wrong? I have searched long

Send more than 261 bytes to Java Card with Android NFC

ⅰ亾dé卋堺 提交于 2019-12-06 04:04:22
I want to send an APDU with a length of 1699 bytes via NFC (class IsoDep ) to a Java Card smartcard. I get the error java.io.IOException: Transceive length exceeds supported maximum My phone is a Samsung Galaxy S7. I use extended-length in my applet on the card. I have verified that the card supports extended length. I tested this via pyapdutool by sending an APDU with 4000 bytes to the card. I found that when I write this code, the result is false : final Tag t = (Tag) tag; myTag = IsoDep.get(t); boolean result = myTag.isExtendedLengthApduSupported(); I have this in my manifest: <activity

NFC APDU READ command performance tuning

走远了吗. 提交于 2019-12-05 05:39:04
问题 I am reading several hundred bytes from a DESFire card using APDU commands. The data application is authenticated, and the response MAC'ed. I submit a series of READ_DATA commands (0xBD), each retrieving 54 bytes+MAC while increasing read offset for each command. Will this operation go much quicker if I use a long READ with ADDITIONAL_FRAME (AF) instead of many sequential reads? I understand that a simple AF is 1 byte vs 8 bytes for a full READ DATA command, thus reducing the number of bytes

MIFARE Classic: How to find to good Access Byte value

隐身守侯 提交于 2019-12-04 06:17:43
问题 My aim is to have only KEY A authentification and disable Key B (used space to store data). I read these documentations: http://www.nxp.com/documents/data_sheet/MF1S503x.pdf http://dangerousthings.com/wp-content/uploads/2012/08/NFC-Access-Control-for-Mifare-S50.pdf I understand how to calculate the hexadecimal values of these three bytes. But I don't understand how to choose the good data block and access byte rules : Data Block rule Here, I want to keep only key A (R & Write data) and