Hi,
we have some cards that work fine on Windows with CCID readers,
and also fine with the non-CCID ACRS38U reader on Linux.
But on Linux with 4 CCID readers, some cards have some
communication problem. Every few 100-200 APDUs, there's a delay
of 60 sec between the command and the response APDU; after which
the communication just continues (until the same problem occurs
some time later). It happens with various commands (Read Binary,
Select File, Verify PIN, ..)
So from the same batch of cards (with the same chip and OS), some
have the above problem and some not.
Below are the end of the CCID and USB logs, where we send the
same Read Binary to the card, until we got the 1 minute delay.
It looks like the CCID log says that the ccid driver had to wait
for 1 minute before the response APDU came in; while the USB
log (2nd row = time in µsec) seems to suggest that the response
APDU was actually send back to the PC (??)
Here's the ATR is, it's a pretty fast card.
ATR: 3B 7D 95 00 00 80 31 80 65 B0 36 01 01 C8 83 01 90 00
TS = 0x3B --> Direct Convention
T0 = 0x7D --> Y(1): b0111, K: 13 (historical bytes)
TA(1) = 0x95 --> Fi=512, Di=16, 32 cycles/ETU (125000 bits/s at 4.00 MHz,
156250 bits/s for fMax=5 MHz)
TB(1) = 0x00 --> VPP is not electrically connected
TC(1) = 0x00 --> Extra guard time: 0
If someone has any idea of what might be happening here...?
Thx,
Stef
CCID log:
[...]
00000011 commands.c:1585:CmdXfrBlockTPDU_T0() T=0: 5 bytes
00000017 -> 000001 6F 05 00 00 00 00 C2 00 00 00 00 B0 00 00 01
00009139 <- 000001 80 03 00 00 00 00 C2 00 00 00 30 90 00
00000022 SW: 30 90 00
00000012 winscard_svc.c:602:ContextThread() TRANSMIT rv=0x0 for client 10
00000656 winscard_svc.c:315:ContextThread() Received command: TRANSMIT from
client 10
00000082 winscard.c:1551:SCardTransmit() Send Protocol: T=0
00000020 APDU: 00 B0 00 00 01
00000016 ifdhandler.c:1280:IFDHTransmitToICC()
usb:08e6/3478:libudev:0:/dev/bus/usb/002/006 (lun: 10000)
00000016 commands.c:1585:CmdXfrBlockTPDU_T0() T=0: 5 bytes
00000029 -> 000001 6F 05 00 00 00 00 C3 00 00 00 00 B0 00 00 01
60009445 <- 000001 80 03 00 00 00 00 C3 00 00 00 30 90 00
// 60.009.445 µsec
00000027 SW: 30 90 00
00000013 winscard_svc.c:602:ContextThread() TRANSMIT rv=0x0 for client 10
00006754 winscard_svc.c:307:ContextThread() Client die: 10
00000033 winscard.c:204:SCardReleaseContext() Releasing Context: 0x1039C02
USB log (output of /sys/kernel/usb/usbmon/xx):
[...]
e36ec180 91087312 S Bo:2:006:2 -115 15 = 6f050000 0000c200 000000b0 000001
// CMD APDU = 00 B0 00 00 01
e36ec180 91087469 C Bo:2:006:2 0 15 >
e4094000 91087658 S Bi:2:006:2 -115 16384 <
e4094500 91087673 S Bi:2:006:2 -115 16384 <
e4094080 91087677 S Bi:2:006:2 -115 16384 <
e4094100 91087682 S Bi:2:006:2 -115 16384 <
e4094280 91087686 S Bi:2:006:2 -115 20 <
e4094000 91096303 C Bi:2:006:2 -121 13 = 80030000 0000c200 00003090 00
// RESP APDU = 30 90 00
e4094500 91096317 C Bi:2:006:2 -104 0
e4094080 91096320 C Bi:2:006:2 -104 0
e4094100 91096322 C Bi:2:006:2 -104 0
e4094280 91096324 C Bi:2:006:2 -104 0
e9be2780 91097314 S Bo:2:006:2 -115 15 = 6f050000 0000c300 000000b0 000001
// CMD APDU = 00 B0 00 00 01
e9be2780 91097472 C Bo:2:006:2 0 15 >
e9be2c00 91097559 S Bi:2:006:2 -115 16384 <
e9be2c80 91097567 S Bi:2:006:2 -115 16384 <
e9be2a80 91097572 S Bi:2:006:2 -115 16384 <
e9be2b80 91097577 S Bi:2:006:2 -115 16384 <
e9be2980 91097581 S Bi:2:006:2 -115 20 <
e9be2c00 91106280 C Bi:2:006:2 -121 13 = 80030000 0000c300 00003090 00
// RESP APDU = 30 90 00
e9be2c80 91106295 C Bi:2:006:2 -104 0
e9be2a80 91106297 C Bi:2:006:2 -104 0
e9be2b80 91106299 C Bi:2:006:2 -104 0
e9be2980 91106301 C Bi:2:006:2 -104 0
e158a500 151113647 C Ii:2:006:1 -2:16 0
// delay of 60.007.346 µsec
e158a500 151113869 S Bo:2:006:2 -115 10 = 65000000 0000c400 0000
e158a500 151113952 C Bo:2:006:2 0 10 >
e9b12500 151114851 S Bi:2:006:2 -115 10 <
e9b12500 151114947 C Bi:2:006:2 0 10 = 81000000 0000c400 0000
e9b12500 151115079 S Ii:2:006:1 -115:16 8 <
e9b12500 156115192 C Ii:2:006:1 -2:16 0
e9b12500 156115338 S Bo:2:006:2 -115 10 = 65000000 0000c500 0000
e9b12500 156115457 C Bo:2:006:2 0 10 >
eab7da00 156115852 S Bi:2:006:2 -115 10 <
eab7da00 156116457 C Bi:2:006:2 0 10 = 81000000 0000c500 0000
eab7da00 156116618 S Bo:2:006:2 -115 10 = 63000000 0000c600 0000
eab7da00 156116711 C Bo:2:006:2 0 10 >
eab7da00 156116978 S Bi:2:006:2 -115 10 <
_______________________________________________
Muscle mailing list
[email protected]
http://lists.drizzle.com/mailman/listinfo/muscle