[gpg-agent] Empty OPTION xauthority=

Werner Koch wk at gnupg.org
Sun Mar 3 10:05:07 CET 2024


Hi!

On Sat,  2 Mar 2024 20:54, mcepl at cepl.eu said:

> am running it on host with systemd --user services (configuration

Take care, the use of systemd is racy and support will be removed in
2.6.

> gpg: all values passed to '--default-key' ignored
> gpg: keydb_search failed: IPC syntax error

(You may use --debug=ipc alsowith gpg to see what is going on)

> 2024-03-02 10:53:20 gpg-agent[2434] DBG: chan_10 <- OPTION xauthority=

gpg-gent receives this from gpg.  Look:

$ gpg-connect-agent
> option xauthority= 
ERR 67109140 IPC syntax error <GPG Agent> - option argument expected
> option xauthority
OK

gpg takes the value for xauthority from the envvar XAUTHORITY.  In your
case it seems that this envvar is set to the empty string which results
in the above synax error.  Using xauthority without a value and thus
without the '=' removes the value from gpg-agent's environment.

In theory it would be possible to ignore the empty string but given that
we have the code this way for 20 year the risk of a regression is to
high.  Please figure out why XAUTHORITY is set to the empty sting.
XAUTHORITY is only needed if you don't use ~/.Xauthority to store the
X11 magic cookies; see xauth(1).


Shalom-Salam,

   Werner


-- 
The pioneers of a warless world are the youth that
refuse military service.             - A. Einstein
-------------- next part --------------
A non-text attachment was scrubbed...
Name: openpgp-digital-signature.asc
Type: application/pgp-signature
Size: 247 bytes
Desc: not available
URL: <https://lists.gnupg.org/pipermail/gnupg-users/attachments/20240303/5315c022/attachment-0001.sig>


More information about the Gnupg-users mailing list