I can reproduce the behavior reliably, which persists since I've stopped a gdb session that locked a token with SCardBeginTransaction without calling SCardEndTransaction (though I'm not sure whether locking is the root cause of the problem).
I forgot to mention that unplugging the token or restart pcscd makes the token available again. However, executing the same commands causes the problem, again.
I was debugging an OpenSC feature to cope with multiple applets on a single token. Unfortunately the card (i.e. token) hangs while pcscd is expecting a response from
InterruptRead
during a communication to the PIV applet (pcscd-log.txt, lsusb.txt). I'm using Debian's PCSC-Lite 1.8.20-1 and libccid 1.4.26-1.I can reproduce the behavior reliably, which persists since I've stopped a
gdb
session that locked a token withSCardBeginTransaction
without callingSCardEndTransaction
(though I'm not sure whether locking is the root cause of the problem).