[Twisted-Python] Conch filetransfer *client* example?
Hello all! I'm a Twisted *and* Python beginner, so please don't treat me badly. :-) I'm looking for a way to transfer files via SFTP (or SCP) and, as I'm going to use conch to execute commands remotely (already did some working tests), I'd like to use the same package to transfer some files (copying them from the twisted-running host to the remote one). I have nothing more than a ssh server on the remote host, can't even rely on a python interpreter, so please don't suggest me to transfer files some other way. Does anyone have a simple example showing how to use the *client* classes of twisted.conch.ssh.filetransfer? I'm really stuck on this... Thanks to anyone that will reply! Cheers, Matteo
On Thu, Apr 05, 2007 at 12:08:42PM +0200, matteo acerbi wrote:
Hello all!
I'm a Twisted *and* Python beginner, so please don't treat me badly. :-) Hi matteo,
I'm new here myself.
I'm looking for a way to transfer files via SFTP (or SCP) and, as I'm going to use conch to execute commands remotely (already did some working tests), I'd like to use the same package to transfer some files (copying them from the twisted-running host to the remote one).
<snip!>
Does anyone have a simple example showing how to use the *client* classes of twisted.conch.ssh.filetransfer? I had trouble finding examples as well. Try 'twisted/conch/scripts/cftp.py', 'conch.py' and 'tkconch.py'.
Note: I don't think any of them work on Windows (not sure about 'tkconch.py') and there are a couple of minor bugs, patches here: http://twistedmatrix.com/trac/ticket/2519 Hope that helps, regards, John.
2007/4/5, John Popplewell <john@johnnypops.demon.co.uk>:
I had trouble finding examples as well. Try 'twisted/conch/scripts/cftp.py', 'conch.py' and 'tkconch.py'.
I hadn't noticed those ones!
Note: I don't think any of them work on Windows
Luckily I don't need Windows. :-)
and there are a couple of minor bugs, patches here: http://twistedmatrix.com/trac/ticket/2519
Hope that helps,
That surely will! Thanks a lot to both you and Andrew. Regards, Matteo
matteo acerbi wrote: [...]
Does anyone have a simple example showing how to use the *client* classes of twisted.conch.ssh.filetransfer?
It's not a particularly simple example, but the "cftp" program that comes with Conch (see bin/conch/cftp and twisted/conch/scripts/cftp.py if you're looking at SVN checkout) is an example of an SFTP client using Conch. -Andrew.
participants (3)
-
Andrew Bennetts -
John Popplewell -
matteo acerbi