[pkg-gnupg-maint] Bug#814584: gnupg2: gpg2 --card-status fail on armel / Raspberry Pi - "Card error"

Petter Reinholdtsen pere at hungry.com
Sat Feb 13 08:42:45 UTC 2016


Package: gnupg2
Version: 2.1.11-5
Severity: important

Hi.

I'm trying to get a GnuPG smartcard working with gnupg/gnupg2 on a
Raspberry Pi running Freedombox (ie Debian armel).  This do not work.
I'm not sure if the problem is in gnupg2 or some other package (like
pcscd, scdaemon or the kernel).  Feel free to reassign as you see fit.
Starting with gnupg2 instead of gnupg as the former seem to be where the
development is happening.

I'm testing using a smart card that work just with with both gpg and
gpg2 on amd64.

When I insert the smart card, it is recognized by the kernel as a
Gemalto USB device.  But when I try to get the card status, I only get
this error (typed from screen, might have typos):

  % gpg2 --card-status
  gpg: selecting opengpg failed: Card error
  gpg: OpenPGP card not available: Card error
  %

When I try the same using gpg (v1), I get this (typed from screen):

  % gpg --card-status
  gpg: detected reader `Gemalto USB shell Token V2 (0F9E69C2) 00 00'
  gpg: pcsc_connect failed: unresponsive card (0x80100066)
  gpg: apdu_send_simple(0) failed: general error
  Please insert the card and hit enter or enter 'c' to cancel: c
  gpg: selecting opengpg failed: general error
  gpg OpenPGP card not available: general error
  %

The syslog contain messages like this from pcscd:

  pcscd[1596]: 99999999 ccid_usb.c:813:ReadUSB() read failed (1/4): -7
    LIBUSB_ERROR_TIMEOUT
  pcscd[1596]: 00000096 ifdwrapper.c:369:IFDStatusICC() Card not
    transacted: 612
  pcscd[1596]: 00000032 eventhandler.c:3333:EHStatusHandlerThread() Error
    communicating to Gemalto USB Shell Token V2 (0F9E69C2) 00 00

Any idea what can be wrong here?  I would love to get GnuPG smart cards
working with Freedombox.

My only ideas is something is wrong with the armel architecture support
of some of the packages involved, or the Raspberry Pi is unable to
provide enough power to the smart card reader and smart card for the
smart card to work.  Not quite sure how to figure out if any of these
ideas are correct.

These are some of the packages involved (I installed them manually as
the machine is offline):

  dirmngr               2.1.11-5
  gnupg-agent           2.1.11-5
  gnupg2                2.1.11-5
  libassuan0            2.4.2-2
  libccid               1.4.22-1
  libgnutls30           3.4.9-2
  libksba8              1.3.3-1
  libncursesw5          6.0+20151024-2
  libnpth0              1.2-2
  libpcsclite1          1.8.15-1
  libsecret-1-0         0.18.4-1
  libsecret-common      0.18.4-1
  libtinfo5             6.0+20151024-2
  pcscd                 1.8.15-1
  pinentry-curses       0.9.7-3
  scdaemon              2.1.11-5

-- 
Happy hacking
Petter Reinholdtsen



More information about the pkg-gnupg-maint mailing list