Connect with an SSH key through an agent
KryoDesk can sign SSH logins with keys held by an SSH agent, so the private key never has to be read by KryoDesk. This guide sets that up and checks it.
1. Load the key into an agent
Section titled “1. Load the key into an agent”macOS ssh-agent (started by launchd, socket in SSH_AUTH_SOCK):
ssh-add --apple-use-keychain ~/.ssh/id_ed25519ssh-add -l # lists the loaded keys with their SHA-256 fingerprintsFor a FIDO security key ([email protected]) the agent must be built with FIDO support.
If the macOS agent refuses to sign with the key, use an agent from Homebrew’s OpenSSH (brew install openssh) and enter its socket in step 2:
eval "$(/opt/homebrew/bin/ssh-agent -a ~/.ssh/agent.sock)"/opt/homebrew/bin/ssh-add ~/.ssh/id_ed25519_skAgent socket in step 2 is then ~/.ssh/agent.sock.
The OpenSSH agent of Windows (service ssh-agent, pipe \\.\pipe\openssh-ssh-agent) is
stopped by default. Start it once in PowerShell as administrator:
Get-Service ssh-agent | Set-Service -StartupType AutomaticStart-Service ssh-agentThen, as your user:
ssh-add "$env:USERPROFILE\.ssh\id_ed25519"ssh-add -l # lists the loaded keys with their SHA-256 fingerprintsPuTTY’s Pageant works too: KryoDesk asks it when the OpenSSH pipe does not answer.
2. Point KryoDesk to the agent
Section titled “2. Point KryoDesk to the agent”Open Settings → Connections → SSH Agent:
- Use the system SSH agent (
SSH_AUTH_SOCK) must be on (the default). - Agent socket:
Leave empty for the macOS agent. For another agent enter its socket, for example
~/Library/Group Containers/2BUA8C4S2C.com.1password/t/agent.sock (1Password) or
~/Library/Containers/com.maxgoedjen.Secretive.SecretAgent/Data/socket.ssh (Secretive).
KryoDesk started from the Dock gets launchd’s SSH_AUTH_SOCK, not one exported in your shell
profile. An agent started in ~/.zshrc is reached only through Agent socket.
Leave empty for the OpenSSH agent of Windows (or a pipe named in SSH_AUTH_SOCK). Another agent
is entered as its named pipe, \\.\pipe\<name>; a value that is not a pipe is ignored with
… is not a local pipe (\\.\pipe\...): ignored. Pageant needs no entry: it is tried last.
- Apply or OK.
3. Set the session
Section titled “3. Set the session”In the session dialog of the server:
- Specify username: the remote login.
- Advanced SSH settings → Authentication: Auto (agent, keys, then password).
- Use private key: off, unless you want a key file as fallback.
4. Connect and check
Section titled “4. Connect and check”Double-click the session. The tab shows Connecting to host:22..., the host key check on the
first connection (answer yes after comparing the fingerprint), then the shell. No passphrase
prompt appears, because the agent signs.
With a security key the tab prints Touch the security key: <algorithm> <fingerprint> once the
server has accepted the key; touch it (and enter its PIN if the agent asks).
When it does not work
Section titled “When it does not work”| What the tab shows | Cause and fix |
|---|---|
| A password prompt | The server accepted none of the agent’s keys. Check ssh-add -l and the server’s ~/.ssh/authorized_keys. |
SSH agent <path> (Settings → Connections → SSH Agent): … |
Agent socket cannot be opened. Check the path and that the agent runs. |
The server closed the connection during authentication (too many failed attempts? …) |
The agent offered more keys than MaxAuthTries allows. Remove keys from the agent, or set Authentication to Private key only with the key file. |
The agent refused to sign with … (SSH_AGENT_FAILURE) |
Security key not touched in time, wrong PIN, key not plugged in, or an agent without FIDO support. |
… is a FIDO security key …: the file holds only a handle |
A security key file was set as Use private key or in Built-in Agent Keys. Load it into an agent instead (step 1). |
Without an external agent
Section titled “Without an external agent”KryoDesk has its own agent for key files. In Settings → Connections → SSH Agent → Built-in Agent
Keys use Add Key… to add ~/.ssh/id_ed25519. With Auto authentication every session
tries these keys after the system agent. An encrypted key asks for its passphrase once per app run
(and offers to save it in the vault); the decrypted key stays in memory until Unload Keys, the app lock or
quitting KryoDesk. After a lock the next connection decrypts the key again (passphrase from the
vault or typed in the tab); connections already open keep running.