Android: Authenticating with NXP MiFare Ultralight C
Below is an example java code to perform Ultralight-C authentication as described in MF0ICU2 / MIFARE Ultralight C – Contactless ticket IC document (chapter 7.5.5 — 3DES Authentication, page 15): public void authenticate(byte[] key) throws CardException { System.out.println(“AUTHENTICATE”); byte[] encRndB = transmitRaw(new byte[] { 0x1A, 0x00 }); if((encRndB.length!=9)||(encRndB[0]!=AF)) { throw new RuntimeException(“Invalid response!”); } encRndB=Arrays.copyOfRange(encRndB, … Read more