Hi,

253 makes sense.  That reader has a one byte value to specify length so on
the return it can send the maximum of FF (255) bytes which is
253 Data bytes plus 2 status bytes.  This is just a limitation of the reader.

Best Regards,
Dave

>Hi,
>
>I've done some tests, thanks to  David Corcoran and
>Tommaso Cucinotta, I've modified the ReadBinary() function in smartsign.
>If I try to read 0xFF bytes at once I get an error .
>
>By now, I've changed the ReadBinary() function in the smart_util.c
>in this way:
>
>while (len > 0) {
>    if (len <= 253)
>      partial = len;
>    else
>        // before
>      // partial = 255;
>
>       // now
>        partial=253;
>
>
>I've tried differents values for "partial", "253" is the highest that worked.
>with 254 I would get the same error. Why does this happen?
>
>
>
>       Christian
>
>
>
>> >David Corcoran wrote:
>> > You might try modifying the code to try and read binary smaller amounts
>> > instead of FF you might try a lower number just to try and track down the
>> > problem.
>
>> Tommaso Cucinotta wrote:
>> You can try this modifying the ReadBinary() function in smart_util.c
>> There you have a loop in which 0xFF bytes are read at once, modify the
>> value to something smallest. Please, consider that you should (perhaps)
>> modify WriteBinary() too, if it worked.
>>
>> Please, let me know if that works, bye,
>>
>>      Tommaso.
>***************************************************************
>Linux Smart Card Developers - M.U.S.C.L.E.
>(Movement for the Use of Smart Cards in a Linux Environment)
>http://www.linuxnet.com/smartcard/index.html
>***************************************************************


David Corcoran                                  Purdue University
1008 Cherry Lane
West Lafayette, IN 47906
[EMAIL PROTECTED]
765 - 427 - 5147                                http://www.linuxnet.com


***************************************************************
Linux Smart Card Developers - M.U.S.C.L.E.
(Movement for the Use of Smart Cards in a Linux Environment)
http://www.linuxnet.com/smartcard/index.html
***************************************************************

Reply via email to