Yubico / yubikey-manager

Python library and command line tool for configuring any YubiKey over all USB interfaces.
https://developers.yubico.com/yubikey-manager/
BSD 2-Clause "Simplified" License
876 stars 125 forks source link

ykman otp : Failed to connect to the device on OSX Sonoma 14.1.1 #581

Open justinpitts opened 11 months ago

justinpitts commented 11 months ago

Steps to reproduce

I ran the following command in zsh 5.9 in iterm 3.4.22

ykman --device 11501162 otp static -k US --no-enter 2

Expected result

ykman prompts me for a new value for the slot

Actual results and logs

WARNING: Failed opening device
WARNING: Failed opening device
WARNING: Failed opening device 
WARNING: Failed opening device
WARNING: Failed opening device
WARNING: Failed opening device
WARNING: Failed opening device
ERROR: Failed to connect to the device`

This is a persistent failure. I reproduce it every time I attempt it.

Other info

Iterm.app has been granted the Input Monitoring permission. Upon encountering this error, I removed and re-added the Input Monitoring permission from Iterm.app This functionality was previously working. I rotate this OTP password every 90 days, and have done so for this key at least 10 times. This may well be the first time I have done so since upgrading to Sonoma.

justinpitts commented 11 months ago

I am able to update this OTP slot on this key on a different M1 Mac running Sonoma.

rrotter commented 3 weeks ago

You have to enable "Input Monitoring" for Terminal.app (or iTerm, or whatever terminal you're using).

System Settings -> Privacy & Security -> Input Monitoring

Credit: https://www.reddit.com/r/yubikey/comments/176l5is/is_anyone_else_having_issues_using_a_yubikey_with/