| Home | Quick Start | Concepts | JCOP Shell | APIs | JCOPsim | Specifications | Command Line | FAQ | Release Notes | |
Additional JCOP on-card API: Mifare™ APIIntroductionCertain versions of JCOP feature an applet programmer's interface (API) that is beyond the scope of the APIs described in the general specifications. When present, the API described in this document is primarily concerned with access to the Philips Mifare™ data structures contained in the JCOP3, i.e., the dual-interface, versions of JCOP cards running on Philips P8RF5016 controllers. This document describes this Mifare™ API. It is not of relevance for other purposes and should then be disregarded. Mifare™ is a specification owned by Philips Semiconductors, and any questions concerning its operation should be directed to Philips. PackageThe code for accessing the Mifare™ data sections is contained in the class
Any code that shall make use of this API has to Constants
Method
The parameters have the following meaning:
The method returns a (short)0, if access was successful, a negative value otherwise. An
Sample CodeSample code making use of this API is listed below:
CaveatsIt has to be noted that code written against this API will only run on JCOP3 cards. It will not run on generic JavaCard/OpenPlatform compliant cards, and it will also not run on JCOP10 or JCOP20 cards. The error condition reflecting this will be a failure to load the applet containing this code. This is due to a reference to the Mifare™ code in the Export File (cf. JavaCard Specifications for further explanations on this) which will be reflected in the CAP file generated. The handling for block 0 is special in one regard from the handling of the other blocks: Block 0 contains the Mifare ID, and hence, is freely readable (without password). Therefore, the result of a MIFARE_PASSWORD_READ access to block 0 is returned at the actual offset location specified above. Related specificationIn order to make use of the Mifare™ API, it may be necessary to know how the Mifare Password is generated from the Mifare Sector Keys. A companion document from Philips Semiconductors describes this algorithm: It is available in this distribution and accessible over this link (Reproduced with permission of Philips Semiconductors BU ID). When reading the specification, equate 'User OS' with 'JCOP' to aid the understanding in this context. | |
|
| |
| Top | Legal Disclaimer | Copyright (c) 2001, 2002, 2003, 2004 IBM Corporation. All rights reserved. | Version 1.0.3.3 (200502081256). |