On Thursday, January 19 at 11:46AM, Szabó Áron wrote:
> 
> Hi,
> 
> I have to test a rather old Bull card with the OpenSC v0.12.2 on Windows, I 
> try to retrieve all the stored files by using "SELECT FILE" and "READ BINARY" 
> APDU commands (after performing a successful authentication by using 
> "VERIFY").
> 
> I can easily get the content of the MF (3F00) but I also get the same content 
> for any other file I select and read. Is it possible that the file ID 
> parameter of "SELECT FILE" can not be evaluated in my case? As you can see 
> below, I select and read the 3F00, 17FF, 2F02 and I always got the same 
> content which is stored in the 3F00 (I checked it with another tool). Any 
> idea?
> 
> Best regards,
> Aron
> 
> ---
> 
> opensc-tool.exe --atr -v
> Using reader with a card: OMNIKEY CardMan 3621 0
> Connecting to card in reader OMNIKEY CardMan 3621 0...
> Using card driver Default driver for unknown cards.
> Card ATR:
> 3B 67 00 00 29 20 1A 01 78 90 00 ;g..) ..x..
> 
> opensc-tool.exe --send-apdu BC:20:00:00:08:XX:XX:XX:XX:XX:XX:XX:XX
> Received (SW1=0x90, SW2=0x00)
> 
> opensc-tool.exe --send-apdu BC:A4:00:00:02:3F:00
> Received (SW1=0x90, SW2=0x00)
> 
> opensc-tool.exe --send-apdu BC:B0:00:00:00
> Received (SW1=0x90, SW2=0x00):
> 17 FF 06 E4 0E 10 03 DF 0E 2F FF C4 1F 6C 04 71 ........./...l.q
> 2F 03 00 80 B0 BB FF E4 2F 02 00 80 B0 BB FF E5 /......./.......
> 17 01 14 D4 FF FF FF FF FF FF FF FF FF FF FF FF ................
> [...]
> 
> opensc-tool.exe --send-apdu BC:A4:00:00:02:17:FF
> Received (SW1=0x90, SW2=0x00)
> 
> opensc-tool.exe --send-apdu BC:B0:00:00:00
> Received (SW1=0x90, SW2=0x00):
> 17 FF 06 E4 0E 10 03 DF 0E 2F FF C4 1F 6C 04 71 ........./...l.q
> 2F 03 00 80 B0 BB FF E4 2F 02 00 80 B0 BB FF E5 /......./.......
> 17 01 14 D4 FF FF FF FF FF FF FF FF FF FF FF FF ................
> [...]
> 
> opensc-tool.exe --send-apdu BC:A4:00:00:02:2F:02
> Received (SW1=0x90, SW2=0x00)
> 
> opensc-tool.exe --send-apdu BC:B0:00:00:00
> Received (SW1=0x90, SW2=0x00):
> 17 FF 06 E4 0E 10 03 DF 0E 2F FF C4 1F 6C 04 71 ........./...l.q
> 2F 03 00 80 B0 BB FF E4 2F 02 00 80 B0 BB FF E5 /......./.......
> 17 01 14 D4 FF FF FF FF FF FF FF FF FF FF FF FF ................
> [...]
> ---

Your log looks like you are using select and read binary in different
sessions. I think when opensc-tool is done it resets the card's state by
disconnecting (which on some readers means that the card gets
unpowered). I haven't used opensc-tool too much, but I know that
opensc-explorer has a commandline to enter multiple APDUs in one
session.

Cheers, Frank.

Attachment: pgpdXZFTXmEAN.pgp
Description: PGP signature

_______________________________________________
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel

Reply via email to