GNOME Bugzilla – Bug 519487
Should set or at least unset SSH_AGENT_PID
Last modified: 2008-04-16 23:41:20 UTC
Hi, When starting the ssh component, gnome-keyring should also set SSH_AGENT_PID or at least unsetenv() it (or tell gnome-session to do so). This is particularly weird when another agent is still running and you end up with SSH_AUTH_SOCK pointing to g-k, but SSH_AGENT_PID pointing to e.g. ssh-agent... (see bug #519486). I guess this might also happen when another agent goes away. Bye,
True, I can see how that would be confusing. It certainly would be easy enough to set SSH_AGENT_PID However it seemed to be that SSH_AGENT_PID refers to the the 'ssh-agent' process specifically, and does not always correspond to SSH_AUTH_SOCK. It would be interesting to discover which programs are confused by this.
I understand why you didn't want to set SSH_AGENT_PID to the g-k process, but then it should be cleared. I don't know which programs are looking at this env var, but grepping my /usr/sbin, /usr/lib, and /usr/bin returned: /usr/bin/keychain /usr/bin/ssh-agent Other users of this env vars: me, getting confused :)
I regards to preexisting ssh-agent processes, here is a Fedora bug that asks for gnome-keyring to be somewhat more cooperative: https://bugzilla.redhat.com/show_bug.cgi?id=442807
There probably needs to be a GUI for disabling this in the next version of GNOME, but here's several ways that users, distros or admins can disable the gnome-keyring SSH agent: http://live.gnome.org/GnomeKeyring/Ssh As far as the SSH_AGENT_PID this environment variable, it seems this belongs to the 'ssh-agent' process (similar to how GNOME_KEYRING_PID belongs to gnome-keyring-daemon). I could be wrong about this, and I'd certainly be willing to change my opinion (and gnome-keyring) given solid rationale.