ok, so the change fixes one card and breaks another.

lets get back to this issue next year, once we are
all back from vacation.

merry xmas and happy new years :)

Regards, Andreas

Am Freitag 18 Dezember 2009 16:53:51 schrieb Douglas E. Engert:
> This patch may break the PIV card, because it changed the
> line 1792: card->max_send_size = 0xffff;
> 
> 
> The PIV card does not directly support read/write binary,
> but get/put_data commands which transfer the whole object
> using adpu chaining using 255 and 256. Its not using extended
> apdu either.
> 
> To emulate the read/write binary it sets the card_max_* sizes
> to 0xffff to allow the caller to read/write the whole object
> rather then 255 byte chunks or records.
> 
> So the max_*_size values are used in two different ways,
> for read/write and for apdu lengths.
> 
> Since there is no "close" command there is no way to know when
> the last write_binary is done. Using the 0xffff a write is done
> all in one operation.
> 
> The attached patch might work, would would needs to be tested.
> (I am on vacation starting today till after the first, so this
> is not a good time to make a change.)
> 
> The piv_general_io routine that does the sc_transmit_apdu
> is also used for a number of other operations, so a lot of testing
> will be needed.
_______________________________________________
opensc-devel mailing list
opensc-devel@lists.opensc-project.org
http://www.opensc-project.org/mailman/listinfo/opensc-devel

Reply via email to