[paramiko] Paramiko and win-ssh-agent

Patrick Mézard pmezard at gmail.com
Sun Dec 17 02:06:34 PST 2006


Robey Pointer wrote:
> 
> On 27 Nov 2006, at 12:33, Patrick Mézard wrote:
>> Basically, I wrote something compatible with cygwin unix domain 
>> sockets and patch it in the existing paramiko.Agent implementation. It 
>> works for me so... I think the implementation has the following 
>> drawbacks:
>> - completely tied to cygwin unix socket implementation. I think this 
>> is OK, the handshake protocol have been stable for at least a year.
>> - cygwin module reads cygwin /etc/passwd at load time to get user id 
>> and group id. I assumed people have the permissions to read this, 
>> probably OK, at least in a cygwin context.
>> - cygwin root directory is read from PARAMIKO_CYGPATH. It could 
>> probably be done in smarter ways, but it works and is simple. Good 
>> enough for now, will not be hard to improve if necessary.
> 
> There's a lot of cygwin magic in this patch.  Can't cygwin just 
> implement the local-domain socket API and hide all of these details in 
> there?  The stuff about parsing the socket file just looks really fragile.

All the black magic is hidden in cygwin.py, the only reason to patch 
agent.py is I cannot provide non-connected sockets.

I do not really get what you mean by "Can't cygwin just implement the 
local-domain socket API and hide all of these details in there?". Which 
cygwin are you talking about: the python module or the project ? Could 
you elaborate on the code changes you have in mind ? I agree that all 
the hand-shaking stuff relies on Cygwin implementation details but I do 
not see how it can be done otherwise, but by asking cygwin developers to 
keep it stable...

I agree it might be too fragile for you to integrate in Paramiko as 
such. At least people could find the patch on the mailing list if they 
ever need it.
--
Patrick Mézard




More information about the paramiko mailing list