Public bug reported:

Updated to ubuntu 26 from 24 and tmux ssh stopped working for keys with 
passphrase.
Environment


        
      gcr4: 4.4.0.1-8 (Ubuntu 26.04 "Resolute", but see cross-distro report 
below)

        
      gnome-keyring: 50.0-1

        
      openssh-client: 1:10.2p1-2ubuntu3.7

        
      Session: Wayland (GNOME)

Summary gcr-ssh-agent hangs indefinitely when asked to sign an SSH auth request 
with a passphrase-protected ed25519 private key. The spawned ssh-add child 
process enters a busy loop (state R, ~100% CPU on one core) and never returns, 
so the ssh client blocks forever waiting for the signature.
A second ed25519 key that has no passphrase works perfectly through the same 
gcr-ssh-agent instance, so this is specific to passphrase-protected keys, not 
ed25519 in general.
Steps to reproduce


        
      Generate (or use an existing) passphrase-protected ed25519 key: 
ssh-keygen -t ed25519 -f ~/.ssh/id_test (set a passphrase)

        
      Make sure SSH_AUTH_SOCK points at gcr-ssh-agent 
(/run/user/<uid>/gcr/ssh), and the key is known to the agent (ssh-add -l lists 
its fingerprint).

        
      ssh to any host that accepts this key: ssh -vvv user@host

Observed behaviour ssh -vvv output stops permanently at: debug3: 
sign_and_send_pubkey: signing using ssh-ed25519 SHA256:... and never proceeds. 
A child ssh-add <keyfile> process appears under gcr-ssh-agent's cgroup, in 
running state, consuming ~100% of one CPU core, and never exits. Each new 
connection attempt leaves another such process running, so they accumulate (I 
found 8+ stuck processes after normal use, and the gcr-ssh-agent.service had 
accumulated 20+ hours of CPU time).
Expected behaviour Either a GUI/terminal passphrase prompt appears and the 
connection proceeds, or the agent fails fast with a clear error — not an 
infinite spin.
What I tried (did not fix it)


        
      Restarting gcr-ssh-agent.service after confirming DISPLAY and 
WAYLAND_DISPLAY were present in its systemd --user environment (the first 
failure happened to coincide with the service having started before those 
variables were imported, but fixing that and restarting did not resolve the 
hang).

        
      Pre-storing the key's passphrase in the login keyring via 
/usr/libexec/seahorse/ssh-askpass <keyfile> before connecting — the dialog 
appeared, passphrase was entered, but a subsequent connection attempt still 
spawned a spinning ssh-add.

        
      Killing the stuck processes and restarting gcr-ssh-agent.service — the 
next connection attempt reproduces the hang again immediately.

Workaround Setting IdentityAgent none for the affected Host in ~/.ssh/config 
bypasses gcr-ssh-agent entirely for that key and falls back to a normal 
terminal passphrase prompt, which works correctly.
Related reports This looks like the same issue reported independently on 
openSUSE Tumbleweed (different distro, identical symptom and identical stuck 
ssh -vvv log line): 
https://forums.opensuse.org/t/gcr-ssh-agent-causes-ssh-hang-with-ed25519-key/189481

ProblemType: Bug
DistroRelease: Ubuntu 26.04
Package: gcr4 4.4.0.1-8
ProcVersionSignature: Ubuntu 7.0.0-38.38-generic 7.0.14
Uname: Linux 7.0.0-38-generic x86_64
ApportVersion: 2.34.1-0ubuntu0.1
Architecture: amd64
CasperMD5CheckResult: pass
CurrentDesktop: ubuntu:GNOME
Date: Tue Oct 13 13:24:01 2026
InstallationDate: Installed on 2025-08-18 (421 days ago)
InstallationMedia: Ubuntu 24.04.3 LTS "Noble Numbat" - Release amd64 
(20250805.1)
SourcePackage: gcr4
UpgradeStatus: Upgraded to resolute on 2026-10-12 (1 days ago)

** Affects: gcr4 (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug resolute wayland-session

** Attachment added: "ssh_verbose_hang.log"
   
https://bugs.launchpad.net/bugs/2170680/+attachment/6008670/+files/ssh_verbose_hang.log

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2170680

Title:
  gcr-ssh-agent hangs/spins forever when signing with a passphrase-
  protected ssh-ed25519 key

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gcr4/+bug/2170680/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to