
ST22N256
4/8
The product has two execution modes. Java mode
is used w hen JavaCard™ 2.x byte codes are be-
ing executed. Native mode is used for long JavaC-
ard™ byte codes, Native methods and system
routines. The processor enters Java mode when a
dispatch (DISP) instruction is enc ountered. When
executing in Native mode, there are two privilege
levels, User and Supervisor. Some instructions
can only be executed in Supervisor mode.
Instructions are of variable length, from 1 to 4
bytes in Native m ode.
Specia l i nstruct ions ex ist for single -cycle st ack op -
erations, a frequent occurrence in Java code.
Short branches and conditional branche s within a
1 KByte block or the entire 16-MByte instruction
space are supported. T he product has four stages
of pipel ine in Native mode: f etch, decode, execute
and write-back. In Java mode, there are five stag-
es of pipeline: byte code-fetch, byte code-decode,
decode, execu te and write-back.
The CPU core has 16 32-bit general purpose reg-
isters, as well as special registers of variable
length.
The chip also features a very high performance
Asynchronous Serial Interface (ASI) to support
high speed serial communication protocols com-
patible with ISO 7816 standard.
It is manufactured using the highly reliable ST
CMOS E EPR OM technology.
EMBEDDED SOFTWARE
The Hardware Software Interface (HSI) imple-
ments the Hardware abstraction layer. It consists
of C interfaces to the EEPROM memory and pe-
ripherals. The drivers are:
–Non V ola t ile M e m o ry
–Asynchronous Seri al Interface
–Central Interrupt Controller
–Timer
–Random Num ber Generator
–Clock Manager
–Memo ry Protection Unit
–Sensors
–Security
Note:
–The HSI driver software layer is a C-oriented
API allowing efficient and secureaccess to the
peripherals and Non Volatile Memory for
programm ing or erasing.
–Only the OS and JavaCard™ Virtual Mac hi ne
(JVM) domains can access the HSI software
layer (In the following the term OS will refer to
the software layer that is directly interfaced to
the HSI).
CRYPTOGRAPHIC LIBRARY
ST proposes a complete set of firmware subrou-
tine s. T his lib rary is lo cated in a s pec ific R OM a r-
ea. It saves the operating system designer from
coding first layer funct ions and allo ws him to con-
centrate on algorithms, Public Key Cryptography
and Secret Key Cryptography protocols imple-
mentation.
The cryptographic library, located in a specific
ROM area, contains firmware functions for:
■AS YMMETRICA L ALGORITHMS:
–basic math ema tics including modular
squa ring and multiplication for various
lengths;
–modular exponentionati on;
–more elabo rate functions such as RSA
signatures and verifications for modulo length
up to 2048 bits long;
–full internal key generation for signatures/
verifications. This guarantees that the secret
key will never be known outside the chip and
contributes to the overall system security.
–long random numbe r generati on
–SHA-1
–RSA key generation
■SY MMET R IC AL AL GO R ITHMS
–DES, Triple DES
–AES-1 28, AES-192, AES-256