! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
startup segfault when GPG_AGENT_INFO has incomplete information
Status:
RESOLVED: INVALID
Product:
Xfce4-session
Component:
General

Comments

Description Robby Workman editbugs 2014-12-31 02:52:32 CET
This is with xfce4-session 4.11.1git_2fb1b8f

If I do something that probably shouldn't be done (heh), xfce4-session (I think) segfaults on startup: export GPG_AGENT_INFO="$HOME/.gnupg/S.gpg-agent" in any user-specific profile script causes this. 

The reason I did this is attempting to work around a bug in claws-mail's handling of newer gnupg-2.1.x: http://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=3337
Comment 1 Landry Breuil editbugs 2014-12-31 08:15:48 CET
Do you need to have a gpg-agent running to cause the crash ?

Is there a backtrace/coredump ?
Comment 2 Robby Workman editbugs 2014-12-31 09:46:40 CET
Aha. It's because xfce4-session/xfsm-startup.c expects the path to the socket, pid of the agent process, and the agent protocol version (which is *exactly* what it used to be), but I'm setting GPG_AGENT_INFO with only the socket path, so probably xfsm_gpg_agent_pid() is unhappy. As I said, this is something that probably shouldn't be done, and so I'm not convinced that an attempt should be made to "fix" it in xfce. The real problem is in claws-mail, I think, but they don't seem to agree :/  I peeked into the code there, and it looks trivial enough to make it work with *only* new gnupg-2.1.x, but not as trivial to make it work with either, as there's no good way to find out what version of gnupg2 is in use on the system (or at least, I'm not aware of one). Anyway, that discussion is out of scope here, so bah. For the time being, I'll just wrap my claws-mail invocation in a script to set the agent info in its environment and hope the claws devs change their mind.
Comment 3 Robby Workman editbugs 2014-12-31 09:47:07 CET
Sorry, forgot to change the bug status.
Comment 4 Landry Breuil editbugs 2014-12-31 09:54:18 CET
Hm.... i still think it's a valid bug, because xfce4-session should gracefully handle invalid env vars and do the right thing instead of crashing.. no ?
Comment 5 Robby Workman editbugs 2014-12-31 10:10:54 CET
Well, that's a legitimate argument. I'll leave that decision for someone else to make. Reopened.
Comment 6 Eric Koegel editbugs 2015-02-15 11:51:44 CET
I upgraded to gnupg-2.1.2 but can't get xsfm to crash. Can you post a list of steps to reproduce?
Comment 7 Robby Workman editbugs 2017-06-22 08:55:11 CEST
I'm not sure if it will still crash or not, but at this point, the ugly hack I was using isn't needed since claws-mail handles newer gnupg2 just fine. I'm closing this as INVALID :-)

Bug #11412

Reported by:
Robby Workman
Reported on: 2014-12-31
Last modified on: 2017-06-22

People

Assignee:
Xfce Bug Triage
CC List:
4 users

Version

Version:
Unspecified

Attachments

Additional information