PowerShell / PowerShell/Win32-OpenSSH

no-touch-required not working

Open
#2,043 8 comments 5 reactions 1 assignee View on GitHub

@anmenaga is already working on this.

Since Mar 20, 2023.

Area-ssh
Dominant language
No language data
Stars
8.3k
Forks
819
PR merge metrics
No merged PRs in 30d

Description

Prerequisites
  • Write a descriptive title.
  • Make sure you are able to repro it on the latest version
  • Search the existing issues.
Steps to reproduce

Here is my environment

  • Yubikey 5 firmware is 5.4.3
  • SSH Client: Windows 11 - OpenSSH_for_Windows_9.2p1, LibreSSL 3.6.1
  • SSH server: Debian bullseye - OpenSSH_8.4p1 Debian-5+deb11u1, OpenSSL 1.1.1n

I create a new key in Windows 11:

ssh-keygen.exe -t ed25519-sk -O resident -O no-touch-required

I add the public key to ~/.ssh/authorized_keys:

no-touch-required sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1...Do=

When I try to establish a ssh session, I encounter error:

ssh manager@192.168.0.194
sign_and_send_pubkey: signing failed for ED25519-SK "C:\\Users\\engineer/.ssh/id_ed25519_sk": requested feature not supported
manager@192.168.0.194: Permission denied (publickey).

If I don't use -O no-touch-required when create key, the ssh session can start as usual.

Here is the full debug log:

OpenSSH_for_Windows_9.2p1, LibreSSL 3.6.1
debug1: Connecting to 192.168.0.194 [192.168.0.194] port 22.
debug1: Connection established.
debug1: identity file C:\\Users\\engineer/.ssh/id_rsa type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_rsa-cert type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_ecdsa type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_ecdsa-cert type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_ecdsa_sk type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_ecdsa_sk-cert type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_ed25519 type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_ed25519-cert type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_ed25519_sk type 12
debug1: identity file C:\\Users\\engineer/.ssh/id_ed25519_sk-cert type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_xmss type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_xmss-cert type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_dsa type -1
debug1: identity file C:\\Users\\engineer/.ssh/id_dsa-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_for_Windows_9.2
debug1: Remote protocol version 2.0, remote software version OpenSSH_8.4p1 Debian-5+deb11u1
debug1: compat_banner: match: OpenSSH_8.4p1 Debian-5+deb11u1 pat OpenSSH* compat 0x04000000
debug1: Authenticating to 192.168.0.194:22 as 'manager'
debug1: load_hostkeys: fopen C:\\Users\\engineer/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen __PROGRAMDATA__\\ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen __PROGRAMDATA__\\ssh/ssh_known_hosts2: No such file or directory
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ssh-ed25519
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: SSH2_MSG_KEX_ECDH_REPLY received
debug1: Server host key: ssh-ed25519 SHA256:0zsBobXfjndLeRNgGGIeaqMSGPHw1NUy1K7Z73vqLWU
debug1: load_hostkeys: fopen C:\\Users\\engineer/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen __PROGRAMDATA__\\ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen __PROGRAMDATA__\\ssh/ssh_known_hosts2: No such file or directory
debug1: Host '192.168.0.194' is known and matches the ED25519 host key.
debug1: Found key in C:\\Users\\engineer/.ssh/known_hosts:2
debug1: rekey out after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey in after 134217728 blocks
debug1: get_agent_identities: ssh_fetch_identitylist: agent contains no identities
debug1: Will attempt key: C:\\Users\\engineer/.ssh/id_rsa
debug1: Will attempt key: C:\\Users\\engineer/.ssh/id_ecdsa
debug1: Will attempt key: C:\\Users\\engineer/.ssh/id_ecdsa_sk
debug1: Will attempt key: C:\\Users\\engineer/.ssh/id_ed25519
debug1: Will attempt key: C:\\Users\\engineer/.ssh/id_ed25519_sk ED25519-SK SHA256:A5kEAoukCasO+iDri1N98ozIxVdL/aVpiG1kVMGr6NQ authenticator
debug1: Will attempt key: C:\\Users\\engineer/.ssh/id_xmss
debug1: Will attempt key: C:\\Users\\engineer/.ssh/id_dsa
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<ssh-ed25519,sk-ssh-ed25519@openssh.com,ssh-rsa,rsa-sha2-256,rsa-sha2-512,ssh-dss,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,sk-ecdsa-sha2-nistp256@openssh.com,webauthn-sk-ecdsa-sha2-nistp256@openssh.com>
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Trying private key: C:\\Users\\engineer/.ssh/id_rsa
debug1: Trying private key: C:\\Users\\engineer/.ssh/id_ecdsa
debug1: Trying private key: C:\\Users\\engineer/.ssh/id_ecdsa_sk
debug1: Trying private key: C:\\Users\\engineer/.ssh/id_ed25519
debug1: Offering public key: C:\\Users\\engineer/.ssh/id_ed25519_sk ED25519-SK SHA256:A5kEAoukCasO+iDri1N98ozIxVdL/aVpiG1kVMGr6NQ authenticator
debug1: Server accepts key: C:\\Users\\engineer/.ssh/id_ed25519_sk ED25519-SK SHA256:A5kEAoukCasO+iDri1N98ozIxVdL/aVpiG1kVMGr6NQ authenticator
debug1: find_helper: using "C:\\Program Files\\OpenSSH\\ssh-sk-helper.exe" as helper
debug1: client_converse: helper returned error -59
debug1: identity_sign: sshkey_sign: requested feature not supported
sign_and_send_pubkey: signing failed for ED25519-SK "C:\\Users\\engineer/.ssh/id_ed25519_sk": requested feature not supported
debug1: Trying private key: C:\\Users\\engineer/.ssh/id_xmss
debug1: Trying private key: C:\\Users\\engineer/.ssh/id_dsa
debug1: No more authentication methods to try.
manager@192.168.0.194: Permission denied (publickey).
Expected behavior
Able to authenticate a SSH session without touching yubikey
Actual behavior
Prompt `requested feature not supported`
Error details

No response

Environment data
- Yubikey 5 firmware is `5.4.3`
- SSH Client: Windows 11 - `OpenSSH_for_Windows_9.2p1, LibreSSL 3.6.1`
- SSH server: Debian bullseye - `OpenSSH_8.4p1 Debian-5+deb11u1, OpenSSL 1.1.1n`
Version

OpenSSH_for_Windows_9.2p1, LibreSSL 3.6.1

Visuals

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.