#1019426 openssh-client: ssh-agent can leave zombie ssh-pkcs11-help

Package:
openssh-client
Source:
openssh-client
Description:
secure shell (SSH) client, for secure access to remote machines
Submitter:
Julien Palard
Date:
2023-09-26 09:27:03 UTC
Severity:
normal
#1019426#5
Date:
2022-09-09 06:43:37 UTC
From:
To:
Dear Maintainer,

Sometimes, while leaving my Yubikey plugged in during suspend, my laptop wakes up with a running ssh-agent (spawned from gnome-keyring-daemon) itself having a zombie ssh-pkcs11-help.

Looks like it's due to ssh-pkcs11-help segfaulting (another issue probably):

Sep 09 08:31:01 seraph kernel: ssh-pkcs11-help[377564]: segfault at 7ffd01d23d90 ip 00007f254d06b037 sp 00007ffd01d23d90 error 6 in libc.so.6[7f254d028000+16e000]

#1019426#10
Date:
2022-09-24 15:10:18 UTC
From:
To:
probably you could install systemd-coredump.
Then the journal should contain a backtrace where the process would segfault.

More information about collecting more information are here:
https://wiki.debian.org/HowToGetABacktrace

Kind regards,
Bernhard

#1019426#15
Date:
2023-09-26 09:18:33 UTC
From:
To:
Confirmed on openssh-client 1:9.4p1-1, ssh-agent seems not going to pick its dead children processes with wait(), no matter how they die. For example, running `ssh-add -s /usr/lib/x86_64-linux-gnu/opensc-pkcs11.so` with a smart card present will make ssh-agent spawn a ssh-pkcs11-helper to handle it, but the child will always become a zombie without being wait(2)ed after it dies, either terminating gracefully after running `ssh-add -e /usr/lib/x86_64-linux-gnu/opensc-pkcs11.so`, or being kill(2)ed.