gpg-agent shell variable output

Daniel Kahn Gillmor dkg at fifthhorseman.net
Wed Oct 19 23:17:04 CEST 2016


On Wed 2016-10-19 10:09:26 -0400, Justus Winter wrote:
> No, and I don't see why that is necessary here.  getsockname is only
> recently used by gpg-agent in case the sockets are given using
> --supervised, and then we do not need to know their name to supervise
> the sockets or to set some environment variable.  There are two more
> uses for the socket names, 1/ as a fallback file for the pinentry to
> touch after messing with the tty (no idea what's going on here, that's
> what the comment says),

Isn't it also used by gpg-agent to decide whether to die due to it not
listening on its own socket any more?

> 2/ one can ask the gpg-agent for the location of the agent's socket
> and the ssh socket using the 'getinfo' command, but I don't see any
> value in that because in order to talk to the agent one needs to know
> the socket location, and the ssh socket's name is easily derived from
> the socket name.

That assumes that the names match exactly and are derived as expected.
it's possible to generate sockets with different names, and pass them to
the agent directly.  We've said publicly that the way to find the name
of the ssh socket is to ask "getinfo ssh_socket_name", right?

   --dkg



More information about the Gnupg-devel mailing list