Smart card structure.


    Distribution: COMPANY CONFIDENTIAL

    Project:      NC model 1
    Issue:        0.06
    Author(s):    Rich Buckley
    Date:         15-Nov-96
    Last Issue:   0.05
  

Contents.


History

	0.01 04-Jul-96 First created.
	0.02 05-Jul-96 Modified some filenames that were reserved.
	0.03 16-Jul-96 Changed ATR slightly following thoughts on card detection.
	0.04 29-Aug-96 Added synchronous memory card manufacturer codes and new hardware codes. Added the serial number file to the file structure.
	0.06 15-Nov-96 Addition of some and class byte.

Outstanding issues

DES key management to be documented.

Overview

This document describes the information required by a smart card manufacturer to supply either sample cards or volume production cards to Acorn or other licencee. Please note the section "Outstanding issues" which will be used to highlight any incomplete areas of documentation.

ATR

Smart cards send an answer to reset (ATR) to the host system whenever they are reset. Part of the ATR is called "historical data" and consists of up to 15 bytes of data. This data is chosen by the card issuer and is fixed into the card at the time of initialisation.

The following table specifies how the historical part of the ATR will be used to uniquely identify a particular flavour of card.

Field type Length (bytes) Example
Manufacturer code 1 InCard
OS code 1 IOS version 1
Hardware code 1 4k storage
File structure version 1 Version 1 structure
Date of issue 3 Date 960716
Licensee code 3 Acorn
Class byte 1 Instruction class byte
Licensee data 4 For use by licencee

Manufacturer code

This field uniquely identifies the manufacturer of the card. It is envisaged that there will be a central authority to allocate these numbers. The following manufacturer codes have already been allocated.

Manufacturer Code
Reserved 0
Reserved 1
Reserved 2
I2C synchronous 3
Microwire synchronous 4

OS code

This code describes the OS (and its version) present on the card by the specified manufacturer.

Manufacturer code OS description OS code
5 IOS version 1.0 0
6 ICC version 6.1 0
7 their OS 0

Hardware code

This code describes the mask that makes up a particular flavour card by the specified manufacturer. For example data storage capacity.

Manufacturer code Hardware description Hardware code
5 (InCard) 4k storage 0
5 (InCard) 8k storage 1
5 (InCard) 4k storage with DES 2
5 (InCard) 8k storage with DES 3
6 (Orga) 4k storage 0
6 (Orga) 8k storage 1
7 (Schlumberger) 3k storage 1
7 (Schlumberger) 4k storage 2
7 (Schlumberger) 8k storage 3

File structure version

This is a version number used to identify the file structure used on the smart card.
Value Description
1 Initial ATR and file structure
2 ATR including Class Byte and manufacturer code in serial number

Date of issue

The date when the card was initialised. Held as yymmdd with each component held as binary coded decimal.

Licensee code

A unique number used to identify the issuer of the card. It is envisaged that there will be a central authority to allocate these numbers.

Licensee name Licensee code
Acorn 0x000001

Instruction class byte

This is used to determine the instruction class byte for future smart card commands. The following instruction class bytes are used. This is only implemented on version 2 structures as specified in the ATR.

Licensee data

To be allocated at the discretion of the issuer. Might be used to identify distribution channel or retail outlet selling the NC.

File structure

Version 1

The smart card filing system should be populated with the following files. The number of boot blocks included is optional. It needs to be at least one and less than nine. Obviously, smaller size cards will only permit one or two boot blocks.

purpose file id size (bytes) read AC write AC
the following files (EFs) will reside in the root directory.
CHV1 file 0x0000 23 NEV NEV
CHV2 file 0x0100 23 NEV NEV
Serial number 0x0020 16 ALW NEV
directory /nc to keep boot blocks 0x4e43 enough to hold specified files ALW ALW
directory /is to keep isp stuff 0x4955 all remaining space available ALW ALW
the following files (EFs) will reside in the /nc directory.
index file for file id lookup and r/o flags 0x0020 96 ALW CHV1
boot block 1 0x0021 440 CHV1 CHV1
boot block 2 0x0022 440 CHV1 CHV1
boot block 3 0x0023 440 CHV1 CHV1
boot block 4 0x0024 440 CHV1 CHV1
the following file (EF) will reside in the /is directory.
isp specific file 0x0020 all remaining space available CHV1 CHV1

Both CHV codes should be intialised to CHV (hex) 31,32,33,34,ff,ff,ff,ff.

Unblocking CHV code should be initialised to (hex) 03,01,04,01,05,09,02,06.

Both CHV error counter and unblocking counter initial values should be at maximum.

The serial number contained in the file /0020 should be formatted as shown in the table below.

Byte(s) Description
0 Manufacturer code
1-15 Binary representation of the serial number