yubikey-agent 是一个用于 YubiKeys 的无缝 ssh-agent。
yubikey-agent 是一个用于 YubiKey 的无缝 ssh-agent。
完全用纯 Go 编写,基于 GitHub.com/go-piv/piv-go 和 golang.org/x/crypto/ssh。
brew install yubikey-agent
brew services start yubikey-agent
yubikey-agent -setup # generate a new key on the YubiKey然后,将以下行添加到你的 ~/.zshrc 中,并重启 shell。
export SSH_AUTH_SOCK="$(brew --prefix)/var/run/yubikey-agent.sock"在 Arch 上,使用 AUR 中的 yubikey-agent 包。
git clone https://aur.archlinux.org/yubikey-agent.git
cd yubikey-agent && makepkg -si
systemctl daemon-reload --user
sudo systemctl enable --now pcscd.socket
systemctl --user enable --now yubikey-agent
export SSH_AUTH_SOCK="${XDG_RUNTIME_DIR}/yubikey-agent/yubikey-agent.sock"在 NixOS unstable 和 20.09(撰写本文时尚未发布)上,你可以
将其添加到你的 /etc/nixos/configuration.nix 中:
services.yubikey-agent.enable = true;这会安装 yubikey-agent 并设置一个 systemd 单元来为你启动
yubikey-agent。
在使用 nix 的其他系统上,你也可以从 nixpkgs 安装:
nix-env -iA nixpkgs.yubikey-agent这会安装软件,但不会安装 systemd 单元。你需要 手动设置服务管理(见下文)。
在其他基于 systemd 的 Linux 系统上,请遵循手动安装说明。
非常欢迎打包贡献。
暂无开放 Issues,或尚未同步最近议题。