I have a YubiKey 4 that it would like to configure for PIV (9a) and signing (9c). If I open YubiKey Piv Manager (1.4.2) then insert my YubiKey 4, everything works great the first time. It recognizes the key and allows me to initialize it. However, if I remove the key and try to do it again, YubiKey PIV Manager (1.4.2) fails to recognize the key.
YubiKey 4 -- PIV applet firmware 4.3.4
YubiKey PIV Manager version 1.4.2
Windows 10 Pro, Creators Update (Version: 1703)
Code:
> systeminfo | findstr /B /C:"OS Name" /C:"OS Version"
OS Name: Microsoft Windows 10 Pro
OS Version: 10.0.15063 N/A Build 15063
I get the following message in the YubiKey PIV Manager UI:
yubico-piv-tool.exe returns the following:
Code:
> .\yubico-piv-tool.exe -astatus
Failed to connect to reader.
I can get YubiKey PIV Manager to recognize the key again if I follow these steps:
- Leave the YubiKey 4 inserted
- Leave YubiKey PIV Manager (1.4.2) open
- Open up Windows Device Manager
- Navigate to "Smart card readers"
- Find the "Microsoft Usbccid Smartcard Reader (WUDF)" device that was added by Windows, and right click to "Uninstall device"
- Remove the YubiKey 4
- Reinsert the YubiKey 4
- VoilĂ ! YubiKey 4 is recognized and I can work with it.
Another interesting thing is that after following the process described above, when you reinsert the YubiKey 4, ever so briefly you see a device appear under "Smart card readers" called "YubiKey 4 OTP+U2F+CCID". This eventually disappears only to be replaced by "Microsoft Usbccid Smartcard Reader (WUDF)" again. It is seemingly present long enough for YubiKey PIV Manager (1.4.2) to get started interacting with the key.
yubico-piv-tool.exe also works after following the process above.
After I remove the key, it won't work again unless I repeat the steps above to uninstall the device before plugging it back in.