|
From: Iain M. <mu...@ds...> - 2006-10-20 08:41:56
|
The next card on my list is a Cyberflex Access 64k V2c (Pegasus). I
had problems installing the MCardApplet, which I tracked down to the
ordering of the "Install Parameters Data Block". Following the
Cyberflex Access V2 Programmer's Guide, I get:
EF04C8027FFFC900
but gpshell produces:
C900EF04C8027FFF
i.e. the C900 (application-specific install parameters) needs to be
after the instance size, not at the start.
So I get:
install_for_install -priv 2 -AID A00000000101 -instAID A00000000101
-pkgAID A000000001 -nvDataLimit 32767
-->
80E60C002005A00000000106A0000000010106A00000000101010208C900EF04C8027FFF0000
<-- 6A80
install_for_install_and_make_selectable() returns 0x80206A80 (6A80:
Wrong data / Incorrect values in command data.)
Whereas the same APDU except with the ordering fixed:
send_apdu -sc 1 -APDU
80E60C002005A00000000106A0000000010106A00000000101010208EF04C8027FFFC9000000
Send APDU: 80 E6 0C 00 20 05 A0 00 00 00 01 06 A0 00 00 00 01 01 06 A0
00 00 00 01 01 01 02 08 EF 04 C8 02 7F FF C9 00 00 00
-->
80E60C002005A00000000106A0000000010106A00000000101010208EF04C8027FFFC9000000
<-- 009000
Recv APDU: 00 90 00
Not sure if this is a bug in GlobalPlatform, or in the card implementation?
~Iain
|