Re: [racket] looking for a simple ssh library.

2013-02-28 Thread Tony Garnock-Jones
On 2013-02-28 5:09 PM, jo wrote: > bidirectional pipe to ssh is needed to achieve this, it is more than > just launching ssh commands. You might have some luck using (process) from racket/system to get input and output ports to the remote process, combined with using (sync) to get the nonblocking

Re: [racket] looking for a simple ssh library.

2013-02-28 Thread jo
python as well and discovered I also need a kind of unbuffered stream (non blocking io). Thanks J. From: Tony Garnock-Jones To: jo Cc: "users@racket-lang.org" Sent: Thursday, February 28, 2013 4:44 PM Subject: Re: [racket] looking for a simple s

Re: [racket] looking for a simple ssh library.

2013-02-28 Thread David Vanderson
Eli, What's the solution here, use 'subprocess' or 'system*' to prevent shell execution? Thanks, Dave On 02/28/2013 07:56 AM, Eli Barzilay wrote: (`system' should almost never be used in public code... Imagine someone using the above code and dealing with the consequences of file names like

Re: [racket] looking for a simple ssh library.

2013-02-28 Thread Michael Wilber
Oh geez, that's a very good point. Thanks for catching that before an attacker does, Eli. Eli Barzilay writes: > 30 minutes ago, Michael Wilber wrote: >> I know it's a hack but for my needs, I just spawn a synchronous ssh >> process, like this: >> >> (define (get-remote-file file) >> (define su

Re: [racket] looking for a simple ssh library.

2013-02-28 Thread Eli Barzilay
30 minutes ago, Michael Wilber wrote: > I know it's a hack but for my needs, I just spawn a synchronous ssh > process, like this: > > (define (get-remote-file file) > (define success? #t) > (define remote-bytes > (with-output-to-bytes > (λ() (set! success? > (system (f

Re: [racket] looking for a simple ssh library.

2013-02-28 Thread Tony Garnock-Jones
On 2013-02-28 9:33 AM, jo wrote: > I am looking for a simple ssh library a la net::snmp. The remote node > does not have racket installed. I want to send and receive commands to > the device. I am working on a project that includes writing an implementation of SSHv2. At the moment it's not quite u

Re: [racket] looking for a simple ssh library.

2013-02-28 Thread Michael Wilber
I know it's a hack but for my needs, I just spawn a synchronous ssh process, like this: (define (get-remote-file file) (define success? #t) (define remote-bytes (with-output-to-bytes (λ() (set! success? (system (format "ssh machinename cat ~a" file)) (and success

[racket] looking for a simple ssh library.

2013-02-28 Thread jo
Hi I am looking for a simple ssh library a la net::snmp. The remote node does not have racket installed. I want to send and receive commands to the device. Thanks J. Racket Users list: http://lists.racket-lang.org/users