kushal.kumaran+pyt...@gmail.com wrote:

>Adam Gold <adamg...@lavabit.com> wrote:
>
>>I'm trying to write a 'simple' script that will set up a socks proxy
>>over ssh and maintain the connection until manually terminated.   It's
>>not possible to use key-based authentication so a password will need
>to
>>be supplied.  Also, note, the user is presented with a list of servers
>>to choose from at the beginning.  The actual ssh command is: 'ssh
>-vNCD
>>23333 user@host'.
>>
>>I've been tinkering with both pexpect and paramiko but fear I'm making
>>a mountain out of a mole hill.  I'm aware both have example scripts
>for
>>ssh forwarding but, to be honest, they are both too complicated (aka I
>>don't know how to customise them).  Here is one script I've attempted
>>to get working and the associated error listing:
>>
>>http://pastebin.com/jj8Fgvwm - script
>>http://pastebin.com/jRA8zpzi - error
>>
>>Could anyone help me either correct the script I've started or suggest
>>an ockham's-razor-adherent alternative!  Many thanks.
>
>The error message indicates that there hostname HOST could not be
>resolved. You need to replace that with the value of the variable HOST.
>
>COMMAND = "ssh -vNDR 23333 {}@{}".format(USER, HOST)
>
>I'm curious to know why you can't use keys. They make things much
>simpler.

Excuse the incorrect ssh command. New mail client tripped me up.


-- 
regards,
kushal
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to