agent losing connection to socket

Philipp Gesang philipp.gesang at intra2net.com
Mon Mar 5 14:06:18 CET 2018


Dear list,

for me the agent (v2.2.5) stops responding after one usage or
two. It doesn’t seem to recover from this state. Here is what I
know:

When resuming after a connection, the agent appears to stop
listening on its socket:

    12922 stat("/home/REDACTED/.config/gnupg", {st_mode=S_IFDIR|0700, st_size=4096, ...}) = 0
    12922 pselect6(8, [3 4 6 7], NULL, NULL, {tv_sec=4, tv_nsec=150980}, {[], 8}) = 0 (Timeout)
    …
    12922 clone(child_stack=0x7fb24f6d7ff0, flags=CLONE_VM|CLONE_FS|CLONE_FILES|CLONE_SIGHAND|CLONE_THREAD|CLONE_SYSVSEM|CLONE_SETTLS|CLONE_PARENT_SETTID|CLONE_CHILD_CLEARTID, parent_tidptr=0x7fb24f6d89d0, tls=0x7fb24f6d8700, child_tidptr=0x7fb24f6d89d0) = 13195
    …
    13195 exit(0)                           = ?
    13195 +++ exited with 0 +++
    12922 <... pselect6 resumed> )          = 0 (Timeout)
    12922 wait4(13055, NULL, WNOHANG, NULL) = 0
    12922 pselect6(8, [6 7], NULL, NULL, {tv_sec=4, tv_nsec=236006}, {[], 8}) = 0 (Timeout)
    12922 wait4(13055, NULL, WNOHANG, NULL) = 0

Where fds 3 and 4 are the gpg and ssh sockets, respectively. 6
and 7 are inotify handles. Agent log:

    2018-03-05 11:26:01 gpg-agent[12922] DBG: chan_10 -> BYE
    …
    2018-03-05 11:26:01 gpg-agent[12922] ssh request handler for sign_request (13) ready
    2018-03-05 11:26:02 gpg-agent[12922] ssh handler 0x7fb24f6d8700 for fd 10 started
    2018-03-05 11:26:02 gpg-agent[12922] ssh handler 0x7fb24f6d8700 for fd 10 terminated
    2018-03-05 11:26:37 gpg-agent[12922] can't connect my own socket: IPC connect call failed
    2018-03-05 11:26:37 gpg-agent[12922] this process is useless - shutting down

At which point the agent continues indefinitely in the above
loop. It doesn’t recover even when HUP’ed.

gpg-agent runs socket-activated in “supervised” mode. Passing
--disable-check-own-socket makes the problem disappear.

What is going on here?

Best,
Philipp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.gnupg.org/pipermail/gnupg-users/attachments/20180305/3707fd00/attachment.sig>


More information about the Gnupg-users mailing list