BUG: ssh-agent unlinks sockets/files it doesn't own.
Damien Miller
djm at mindrot.org
Mon Oct 4 16:35:49 EST 2004
Rich wrote:
> The first ssh-agent survives the ordeal, but finds itself unreachable,
> and without purpose.
>
> I would suggest a couple of changes:
>
> 1) unless bind has been successful, don't unlink the socket.
Yes, I agree. Patch attached.
> 2) teach ssh-agent to either die or rebind if his socket disappears.
> my pref would probably be death, as I find it more elegant than
> killing it with ssh-agent -k.
I don't think it can easily tell if its socket has been unlinked. It is
probably unnecessary if 1 is done anyway.
> The first probably wise for good manners, even though the second will
> solve the problem. note that:
>
>>su
>>ssh-agent -a /etc/passwd
>
> would probably have unpleasant repercussions.
so would "rm -f /etc/passwd", so I think this falls into the case of
"don't do that" :)
-d
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: agentunlink.diff
Url: http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20041004/ef124527/attachment.ksh
More information about the openssh-unix-dev
mailing list