无法通过与 macOS monterey 配合使用的 Yubikey 获得 SSH

Nar*_*ail 21 yubico yubikey

我在使用 openSSH 8.6 的 macOS Monterey 上遵循https://developers.yubico.com/SSH/上的 FIDO U2F 说明,但遇到了以下问题:

~ ssh-keygen -t ecdsa-sk -f ~/.ssh/id_ecdsa_sk
Generating public/private ecdsa-sk key pair.
You may need to touch your authenticator to authorize key generation.
Key enrollment failed: unknown or unsupported key type
Run Code Online (Sandbox Code Playgroud)

有人知道我在这里缺少什么吗?

Mat*_*tti 23

使用 Homebrew 的 OpenSSH

$ brew install openssh
Run Code Online (Sandbox Code Playgroud)

安装后,您必须通过将 openssh 文件夹放在文件的开头来覆盖 PATH 中的文件夹,PATH如下rc所示

$ export PATH=$(brew --prefix openssh)/bin:$PATH
Run Code Online (Sandbox Code Playgroud)

完成此操作并source创建rc文件后,您应该能够生成密钥

在 macOS Monterey 和OpenSSH_8.8p1, OpenSSL 1.1.1l

  • OpenSSH 版本 8.2p1 支持它,但 Apple 专门使用“--disable-security-key”编译标志禁用它。https://github.com/apple-oss-distributions/OpenSSH/pull/1 (5认同)