Skip to content

Drivers License (IC Card) Specification

1. System Overview

  • Standards: ISO/IEC 14443 Type B (NFC), ISO/IEC 7816-4.
  • Encoding:
    • Text: Shift-JIS (JIS X 0208 & JIS X 0201).
    • Photo: JPEG2000.
    • Gaiji (External Char): MMR Compressed Bitmap.
  • Cryptography:
    • Hash: SHA-256.
    • Signature: RSA-2048 (PKCS #1 v1.5).

2. Application Identifiers (AID)

DFAIDPIXDescription
DF1A0 00 00 02 31 01 00 00 00 00 00 00 00 00 00 00Start 01Main Data
DF2A0 00 00 02 31 02 00 00 00 00 00 00 00 00 00 00Start 02Photo Data
DF3A0 00 00 02 48 03 00 00 00 00 00 00 00 00 00 00Start 03RFU (ISO/IEC 18013-2)

3. File Structure & Access Control

ParentEFEF-IDTypeContentSizeRead AccessWrite Access
MFEF012F 01WEFCommon Data17FREE-
MFEF0200 0AWEFPIN Settings3FREE-
MFIEF0100 01IEFPIN 16--
MFIEF0200 02IEFPIN 26--
DF1EF0100 01WEFLicense Info880PIN 1-
DF1EF0200 02WEFRegistered Domicile82PIN 1 & 2-
DF1EF0300 03WEFGaiji264PIN 1-
DF1EF0400 04WEFCondition Changes640PIN 1Forbidden
DF1EF0500 05WEFGaiji Changes663PIN 1Forbidden
DF1EF0600 06WEFDomicile Changes256PIN 1 & 2Forbidden
DF1EF0700 07WEFElectronic Signature578PIN 1-
DF2EF0100 01WEFFace Photo2005PIN 1 & 2-
DF3EF0100 01WEFRFU512PIN 1-

Access Rights Note:

  • If MF/EF02 Byte 1 Bit 1 is 0 (PIN not set), verification is treated as using a Default PIN (****) or skipped.
  • "Condition Changes" (EF04) Read is Forbidden (or treated as PIN1) if PIN is not set.

4. Data Content Details

4.1 Common Data Element (MF/EF01)

TagLenContentEncoding
4511Card Issuer Data (Ver + IssueDate + ExpDate)0201 + HEX
462Pre-issue Data (ManufID + CryptoID)HEX

4.2 License Information (DF1/EF01) - Tag 00 01

TagLenContent
111JIS X 0208 Version
1272Name (Use 2121 space between Last/First)
1332Kana Name
1432Alias Name (Tsusho-mei)
1516Unified Kana Name
167Date of Birth (EraYYMMDD)
1780Address
187Date of Issue (EraYYMMDD)
195Inquiry Number (Ref #)
1A6Color Class (優良, 新規, その他)
1B7Expiration Date (EraYYMMDD)
1C80Condition 1
1D80Condition 2
1E80Condition 3
1F80Condition 4
2024PSC (Public Safety Commission) Name
2112License Number
227Date: Motorcycle/Small Special/Moped
237Date: Others
247Date: Class 2
25..327Date: Individual Categories (Large, Ord, LargeSpec, etc.)
337Date: Semi-Medium
34..3F-RFU

4.3 Registered Domicile (DF1/EF02) - Tag 00 02

TagLenContent
4180Registered Domicile (Honseki)

4.4 Gaiji (DF1/EF03)

Contains bitmap data for characters not in JIS X 0208.

  • Encoding: MMR Compressed Bitmap.
  • Header: 1 byte (Structure/size).
  • Tags: 48 (Gaiji 1), 49 (Gaiji 2).

4.5 Condition Changes (DF1/EF04)

Updates to address, name, or conditions.

  • Tags: 50 (Updated Flag), 51..5F (PSC Change), 60..97 (New Address/Name/Conditions).

4.6 Electronic Signature (DF1/EF07)

  • Hash Input: All data in DF1/EF01, DF1/EF02, and DF2/EF01.
  • Algorithm: SHA-256 hash + RSA-2048 signature.
  • Tag B1: Signature Value (256 bytes).

4.7 Face Photo (DF2/EF01)

  • Tag: 5F 40
  • Format: JPEG2000 (Monochrome).
  • Max Size: 2000 bytes.

5. Command Reference

SELECT FILE (00 A4)

  • P1: 04 (AID) or 02 (EF-ID).
  • P2: 0C (First/Next).

VERIFY (00 20)

  • P1: 00
  • P2: 80 (Current EF / Implicit).
    • Note: The spec implies selecting the IEF or using a Short EF-ID in P2 is possible, but 80 targets the PIN associated with the current context (DF).
  • Data: 4-digit numeric PIN.
  • Retry: 3 times each for PIN1 and PIN2.

READ BINARY (00 B0)

  • P1: 8x (EF-ID MSB) or 00 (Current EF).
  • P2: xx (EF-ID LSB) or Offset.

6. Reference

Released under the MIT License.