[Pcsclite-muscle] OMNIKEY AG 3121 USB not working with libccid 1.4.17 and PCSC-Lite 1.8.11

Sebastien Lorquet sebastien
Tue Jul 15 05:44:00 PDT 2014


Le 15/07/2014 14:22, Ludovic Rousseau a ?crit :
>> P.S. The SELECT-APDU that is sent in the pcsc-lite/src/testpcsc test
>> > program is malformed, because the given P2 requests a FCI struct as
>> > response but Le is not present in the APDU. I propose to change lines
>> > 267-268 from:
>> >    send_length = 7;
>> >    memcpy(bSendBuffer, "\x00\xA4\x00\x00\x02\x3F\x00", send_length);
>> > to:
>> >    send_length = 8;
>> >    memcpy(bSendBuffer, "\x00\xA4\x00\x00\x02\x3F\x00\x00", send_length);
> APDU Case 4 are problematic with PC/SC.
> I will make more tests.

Hello,

I would not say that it depends on PC/SC.

In contactless (aka "T=CL") and T=1 this is no problem, since the card is able
to reply with data even when it was not expected (because the protocol is made
of "packets"). That means that Le is "useless" and may only be used as a hint by
the card.

In T=0 it depends on the card model.

One would expect that Le is mandatory since the card has to know the length of
the next transfer.

But when Le is not transmitted in a command with or without outgoing data, and
the card wants to reply some response data, most javacards and possibly some
other native cards will reply a 61xx code, which asks the user to go formward
with a "GET RESPONSE" (00C00000xx) APDU to retrieve the response data. This can
be used for chained responses, with the card replying 61XX to a "get response" apdu.

S?bastien Lorquet




More information about the pcsclite-muscle mailing list