On 13/11/06, Andreas Jellinghaus <[EMAIL PROTECTED]> wrote:
I had a look at CCID spec 1.10 and - not sure - it seems this is no
longer valid, dwMaxCCIDMessagelength has to be at least 271 bytes
(and max 65544+10 bytes). but that doesn't help, it would be nice
to get the hardware to work.

Can you give me the extract of the CCID specs that says 271 is the
minimal length?

I have CCID specs 1.10 and I found on page 20 in the description of
dwMaxCCIDMessageLength:

 " For extended APDU level the value shall be between 261 + 10
(header) and 65544 +10, otherwise the minimum value is the
wMaxPacketSize of the Bulk-OUT endpoint. "

So 261+10 only applies in extended APDU level. Not in normal APDU level.

I know only 2 readers that can do extended APDU (they are contactless
readers from id3: CL1356T and CL1356D).

so we only have a T=0 problem. the cryptoflex card can do both T=0
and T=1, so if we switched to T=1 by default, we wouldn't have the
issue at all? IIRC we prefer T=1 for reader-pcsc, and pcsc tries
to switch to T=1 if possible?

If the card can do both T=1 and T=0 AND the application requests both
T=1 and T=0 (SCARD_PROTOCOL_T1 | SCARD_PROTOCOL_T0) then PC/SC-lite
selects T=1.

./src/libopensc/reader-pcsc.c uses SCARD_PROTOCOL_ANY so it should
work as described.

  - if we are using t=0, we need to let opensc know what the limits
    for max_send/recv_size are (the driver knows, but we currently have
    no way to let reader-openct know)

I could add support of SCardGetAttrib(.., SCARD_ATTR_MAXINPUT, ..) in
my CCID driver to let the application know the maximum input size. I
don't know if SCARD_ATTR_MAXINPUT can be used for that. Does anybody
have a documentation of the Microsoft SCARD_ATTR_* commands?

Bye,

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

Reply via email to