Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

Guest

Re: Detect UTF-8 with SFTP version 3

I was afraid you say that :). Anyway, I will ask the OpenSSH developers, and report back.
martin

Re: Detect UTF-8 with SFTP version 3

I understand your concerns. If the extension gets to OpenSSH or any fork of it, I'm happy to add support for it to WinSCP.
Cus

Detect UTF-8 with SFTP version 3

Currently OpenSSH, the most commonly used sftp-server implementation only supports SFTP protocol version 3. This version has a serious problem: the character encoding of the filenames is unspecified with it. It would be very useful if one could add a tiny (no more than a few lines) patch to openSSH and with that patch, the sftp-server could give a hint to WinSCP (and other sftp clients) to use UTF-8 filenames. (The current behavior of WinSCP is not to use UTF8 if sftp protocol version is less than 4 or if it's not explicitly requested in the session configuration dialog)

Probably the simplest way to achieve this is to use a custom extension to sftp. Below is a tiny patch to WinSCP that detects this custom extension, and sets the encoding to utf8 when utf8 setting is configured to Auto.

<invalid hyperlink removed by admin>

If anybody has a better idea to make WinSCP detect utf8 filenames even with openSSH, let me know. Asking the users every time to set the UTF-8 setting to "On" is not very user-friendly, the majority of my users don't even know what utf-8 is, they just want things to work :)