#1026423 ykls: Crashes when smartcard reader present

Package:
ykls
Source:
ykls
Description:
Utility for listing connected Yubikeys
Submitter:
Peter Samuelson
Date:
2026-06-25 11:57:01 UTC
Severity:
normal
#1026423#5
Date:
2022-12-19 21:11:27 UTC
From:
To:
$ lsusb | grep -e Yubi -e Smart
Bus 001 Device 098: ID 1050:0407 Yubico.com Yubikey 4/5 OTP+U2F+CCID
Bus 001 Device 099: ID 04e6:5116 SCM Microsystems, Inc. SCR331-LC1 / SCR3310 SmartCard Reader

$ ykls
Reader:  SCM Microsystems Inc. SCR 3310 [CCID Interface] (53311904213994) 00 00
panic: ykpiv ykpiv_connect: Generic Error (-7) - Something went wrong.

goroutine 1 [running]:
main.ohshit(...)
        pault.ag/go/ykpiv/cmd/ykls/ykls.go:31
main.main()
        pault.ag/go/ykpiv/cmd/ykls/ykls.go:44 +0x6bc

====================

If I unplug the smartcard reader, it works:

$ lsusb | grep -e Yubi -e Smart
Bus 001 Device 098: ID 1050:0407 Yubico.com Yubikey 4/5 OTP+U2F+CCID

$ ykls
Reader:  Yubico YubiKey OTP+FIDO+CCID 01 00
Version: 5.2.4
Serial:  [correct]
Slot Authentication (9a): [correct]

====================