SSH Connection Issue with Yubikey 5C NFC on Desktop PC

Greetings,

I am experiencing an issue with SSH connections using my Yubikey 5C NFC key on my desktop PC. Here are the details of my setup and the problem:

Setup

  • Devices: I have a laptop and a desktop PC, both running CachyOS.
  • Yubikey: Yubikey 5C NFC.
  • SSH Key: The same private SSH key is used on both devices.
  • Yubico Software: Yubico Authenticator and Yubico Manager are installed on both devices and they can detect the Yubikey without any issues.
  • Library: libfido2 is installed on both devices.

Problem Description

  • On my laptop, I installed CachyOS with the Yubikey 5C NFC connected. SSH connections to my servers work perfectly without any issues.
  • On my desktop PC, I installed CachyOS without the Yubikey connected. When I try to establish an SSH connection from this device, it fails.

Here is the SSH connection log from my desktop PC:

❯ ssh portainer_01
Confirm user presence for key ED25519-SK SHA256:+/GFk0to2FiJI1j3OBvLu7sgbdKzngID0GuWsu3J0rw
sign_and_send_pubkey: signing failed for ED25519-SK "/home/tony/.ssh/yubikey1": device not found
tony@192.168.1.157: Permission denied (publickey).

Additional Information

  • Both the Yubico Authenticator and Yubico Manager recognize the Yubikey 5C NFC on the desktop PC without any issues.
  • Despite this, SSH cannot seem to locate or use the Yubikey for authentication.

Request for Help

Could anyone help me understand why the SSH connection is not working on my desktop PC but works fine on my laptop? Any guidance on how to resolve this issue would be greatly appreciated.

I installed yubikey-agent as well but it did not solve my problem.
https://aur.archlinux.org/packages/yubikey-agent
Any idea?

I solved the problem as follows:

  1. I created a new private and public key using the following command:
    ssh-keygen -t ed25519-sk
    
  2. I copied the public key to the target machine (portainer_01).
  3. I edited the .ssh/authorized_keys file on the target machine to add the new public key.

However, I have not been able to identify the source of the problem.

1 Like