GrcardSIM » History » Revision 9
Revision 8 (tsaitgaist, 02/19/2016 10:47 PM) → Revision 9/12 (tsaitgaist, 02/19/2016 10:48 PM)
{{>toc}} h1. [[PageOutline]] = GRcard SIM = The GRcard SIM is a programmable GSM SIM card. It uses a mixture of TS11.11 / ISO7816-4 and proprietary commands for programming There is limited card programming support both in http://cgit.osmocom.org/cgit/pysim/ as well as the more interactive http://cgit.osmocom.org/cgit/cyberflex-shell/ h2. == Command reference == To understand this reference, it is assumed that you are familiar with basic knowledge on smartcard technologies, such as standard ISO 7816-3/-4 APDUs and GSM TS 11.11. h3. === Setting the ICCID === Uses a standard UPDATE BINARY (D6) command on the EF.ICCID (2FE2) Security: ADM2 h3. === Setting the IMSI === Uses a standard UPDATE BINARY (D6) command on the EF.IMSI (7F20/6F07) Security: ADM2 h3. === Setting the Access Class === Uses a standard UPDATE BINARY (D6) command on the EF.ACC (7F20/6F78) Security: ADM2 h3. === Setting the SMS Parameters === Uses a standard UPDATE RECORD (DC) command on the EF.SMS (7F10/6F42) Security: ADM2 h3. === Setting the A3/A8 algorithm === Uses a standard UPDATE BINARY (D6) command on the non-standard (2700/6F70) EF The record has a size of 1 byte and is defined as follows: * 01 - COMP128v1 * 02 - COMP128v2 * 03 - COMP128v3 Security: ADM2 h3. === Setting the Ki <pre> === Uses a non-standard APDU {{{80 D4 02 00 10}}}, followed by 16 bytes of Ki Security: none h3. === Setting the PIN1 and PUK1 <pre> === Uses a non-standard APDU {{{80 D4 00 01 10}}} followed by 8 bytes of PIN1 and 8 bytes of PUK1 Security: none h3. === Setting the PIN2 and PUK2 <pre> === Uses a non-standard APDU {{{80 D4 00 02 10}}} followed by 8 bytes of PIN2 and 8 bytes of PUK2 Security: none h3. === Setting the ADM1 + AUK1 <pre> === Uses a non-standard APDU {{{80 D4 01 04 12 03 00}}} followed by 8 bytes of ADM1 and 8 bytes of AUK1 Security: none h3. === Setting the ADM2 + AUK2 <pre> === Uses a non-standard APDU {{{80 D4 01 05 12 03 00}}} followed by 8 bytes of ADM2 and 8 bytes of AUK2 Security: none h3. === Create File <pre> === Uses a non-standard APDU {{{80 CF 00 P2 LEN FID SIZE OPT1 ACC OPT2}}}, specified as follows: * Parameter P2: ** * 00: Create DF ** * 01: Create linear record EF ** * 02: Create transparent EF ** * 03: Create cyclic record EF <pre> * 04: used to create EF.0001 with size {{{0A20}}} * FID: The 2 byte File ID * SIZE: 2 bytes for the transparent EF size; or 1 byte for the number of records, and 1 byte for the record size for linear or cyclic EF <pre> * OPT1: Always {{{0100}}} * ACC: Access conditions (3 bytes), According to TS 11.11, Section 9.3 <pre> <pre> * OPT2: Always {{{FF}}} In case a Directory or EF.0001 is created, OPT1, ACC and OPT2 are replaced with 8-bytes all-zero {{{00000000000000}}} Security: ADM0 h3. === Erase Card <pre> === Uses a non-standard APDU {{{80FE000014 31323334353600001301FF0000000000000000EA}}} Security: none h3. === Authenticate as ADM0 <pre> === Uses a non-standard APDU {{{80 F6 00 00 08 PIN}}}, where per default PIN is {{{0000000000000000}}}