smartcard not working reliable with ccid driver

Jan Niehusmann jan at gondor.com
Thu Mar 31 20:37:28 CEST 2005


Hi,

I have the following problems with gnupg when using the builtin ccid
driver:

1) --card-status is often very slow

   When that happens, strace shows the following line very often:

   ioctl(3, USBDEVFS_REAPURBNDELAY, 0xbfca34f4) = -1 EAGAIN (Resource temporarily unavailable)

2) Decryption does not work, I always get the following error:

   $ gpg test.gpg
   gpg: DBG: asking for PIN 'PIN'
   
   PIN
   gpg: ccid_transceive failed: (0x1000a)
   gpg: apdu_send_simple(0) failed: card I/O error
   gpg: encrypted with 1024-bit RSA key, ID 662A4433, created 2005-03-31
         "Jan Niehusmann (openpgp card test) <jan at gondor.com>"
   gpg: public key decryption failed: general error
   gpg: decryption failed: secret key not available
   
I didn't try many other things, but I found a way to work around that:
With the options --disable-ccid --pcsc-driver /usr/lib/libpcsclite.so.1
gnupg seems to work reliably. (After starting pcscd, of course)

This is on debian unstable, with linux 2.6.12-rc1, on an Asus M2400N
laptop. All packages are current. The reader is the SCM SCR-335 as
provided by kernel concepts.

If you want, I can do some more debugging, to find the cause of this
problem. My time is limited, but I bought the card for playing with it,
and I'll happily spend some spare time if I can help improving gpg.

Jan

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : /pipermail/attachments/20050331/621b5b85/attachment.pgp


More information about the Gnupg-devel mailing list