cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: SFTP transcript

From: Sam Deane <sam_at_elegantchaos.com>
Date: Wed, 10 Apr 2013 21:24:54 +0100

On 10 Apr 2013, at 21:13, Daniel Stenberg <daniel_at_haxx.se> wrote:

> On Wed, 10 Apr 2013, Sam Deane wrote:
>
>> Ah yeah, I guess that makes sense. I was fooled by the existence of the quote commands (chmod/rm/etc) into thinking of it as essentially still a text based protocol, just tunnelled over ssh. If that's not the case, then I can see the problem :)
>
> SFTP is a "subsystem" with the SSH family. The protocol is pure binary and is really very filesystem like in its nature.

Yeah, have actually looked briefly at the spec now, so I understand a bit more :)

>> I'm up for adding the human-readable stuff, but I'll have to have a chat with the guys I'm working with and see if they want me to do it.
>
> To get lots of debug info out of an SFTP session, you need to get data out from libssh2 that might not be there by default. Usually, the best way to trace problem with libssh2 is to build a version of that library with support for libssh2_trace() and then make sure to define CURL_LIBSSH2_DEBUG in lib/ssh.c. It produces a massive amount of detailed SSH-level protocol data and information.

Right.

In this case the desire for a "transcript" is more for parity with the other protocols. It's something that a user can choose to view (although hidden away by default) in the product I'm working on, and is something that can be helpful when debugging customer issues. It's not necessarily something we want for hard-core debugging of the actual code.

Speaking to the other guys I'm working with, it seems like it would probably be easier to add some sort of pseudo-transcript for SFTP at a higher level than curl, so that's probably what I'll do.

If there's anyone out there who's particularly keen to see it added to curl's SFTP layer instead, this is your chance to speak up…

sam deane / @samdeane | elegantchaos.com / @elegantchaoscom | mac and ios software development

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2013-04-10