29.01.2015 Views

Applications & SmartCard : JavaCard - Identification - LIFL

Applications & SmartCard : JavaCard - Identification - LIFL

Applications & SmartCard : JavaCard - Identification - LIFL

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>JavaCard</strong>.Framework.Utils<br />

• Functions for byte array manipulation & comparison<br />

<br />

<br />

<br />

<br />

byte arrayCompare() ; Compares 2 arrays<br />

arrayCopy() ; Copies 1 array into another atomically<br />

arrayCopyNonAtomic() ; Copies 1 array into another<br />

non-atomically<br />

arrayFillNonAtomic() ; Fills an array non-atomically<br />

• Functions for type conversion (short / byte)<br />

short getShort() ;<br />

short makeShort() ;<br />

setShort() ;<br />

,<br />

[ 0E 06 ] 0E 06<br />

0E 06 0E 06<br />

0E 06<br />

0E 06<br />

<strong>JavaCard</strong>.Framework APIs<br />

• AID<br />

• APDU<br />

• Applet<br />

• OwnerPIN<br />

• Util<br />

• JCSystem<br />

The JCSystem class includes a collection of<br />

methods to control applet execution, resource<br />

management, atomic transaction management and<br />

inter-applet object sharing in Java Card.<br />

http://www.lifl.fr/~grimaud/Cours<br />

<strong>JavaCard</strong> System & Framework 53<br />

http://www.lifl.fr/~grimaud/Cours<br />

<strong>JavaCard</strong> System & Framework 54<br />

<strong>JavaCard</strong>.Framework.JCSystem<br />

• 1. Object sharing<br />

• 2. Persistence / transience<br />

• 3. Transaction atomicity<br />

<strong>JavaCard</strong>.Framework.JCSystem<br />

1. Sharing<br />

• Applets can share individual objects with each other<br />

• Once an object is shared, it cannot be unshared<br />

• JCRE Privilege<br />

JCRE has access to all objects regardless if they are shared or not<br />

• getAppletShareableInterfaceObject(AID, byte)<br />

Called by a ‘ client ’ applet to get a ‘ server ’ applet's shareable<br />

interface object.<br />

A ‘ server ’ applet can not be deleted<br />

http://www.lifl.fr/~grimaud/Cours<br />

<strong>JavaCard</strong> System & Framework 55<br />

http://www.lifl.fr/~grimaud/Cours<br />

<strong>JavaCard</strong> System & Framework 56

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!