IETF-SSH archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: solving the SFTP text mode issue



> Judging from the number of times that text file support has been requested
> for SFTP, we might as well do something about it. I suggest that, in the
> next version of the filexfer draft, we document a recommended way for
client
> software to do text file conversion. (On its own, of course, without any
> ugly hacks into the protocol.)
>
> What if we provide an SFTP command that the client could execute to learn
> the line separator on the server machine?
>
> We could then document a text file conversion algorithm such as the
> following:
> 1. The client queries the server about the server's line separator.
> 2. If the server's line separator is the same as the client's, the file is
> transferred in binary mode.
> 3. Otherwise, the client determines whether the file is textual using, for
> instance, the Kermit 8 algorithms mentioned by Jeffrey earlier on this
list.
> If the file is textual, the client converts it.

This is what our server (and clients) do as an sftp connection.

The server sends as part of it's init packet

"new-line%vandyke.com@localhost"
"\r\n"

And the clients look for this to know what to do
with files that are text.

- Joseph






Home | Main Index | Thread Index | Old Index