Subject: Bug#566: [X2Go-Dev] Bug#566: X2Go Client for Windows 4.0.2.1 cannot create C:\Users\<username>\ssh\known_hosts file when the local Windows account username has non-Ascii characters

From: Michael DePaulo <[email-masked]>
Date: Sun, 7 Sep 2014 22:55:13 -0400

Yeah. I think that libssh isn't being compiled with Unicode support,
or at least not under MingW 4.4. It's not 100% clear how to compile a
C library with Unicode support under MinGW and CMake. For example,
recent versions of MinGW let you specify the linker option -municode.
But I cannot find a single release note that states when exactly that
feature was added. I do not know if 4.4 has it or not.

I'm going to try to compile it with MinGW 4.8. I've been meaning to
upgrade to X2Go to MinGW 4.8 and QT 4.8.6 anyway. (bug: #474)

On Sun, Sep 7, 2014 at 8:13 PM, George Trakatelis <[email-masked]> wrote:
> Hi Mike,
>
> 1. If you recompile libssh 0.6.3 with Unicode support and provide me with a download link,
> I will happily test it on all Windows platforms (namely Windows 8, 7, and XP).
>
> 2. I agree.
>
> -George
>
> -----Original Message-----
> From: Michael DePaulo [mailto:[email-masked]]
> Sent: Sunday, September 7, 2014 4:23 PM
> To: George Trakatelis; [email-masked]; Mike Gabriel
> Subject: Re: [X2Go-Dev] Bug#566: X2Go Client for Windows 4.0.2.1 cannot create C:\Users\<username>\ssh\known_hosts file when the local Windows account username has non-Ascii characters
>
> [...]
>
> Hi Mike#1 and George,
>
> 1. What do you think of using toUtf8() instead? I am hoping that will fix the bug regardless of the locale.
>
> I tried changing it to that (bug566.utf8.test.patch), but it still did not fix this bug with the greek username on my system with the locale set to English. It did not introduce a regression for my ASCII user account at least.
>
> If libssh needs to be recompiled for Unicode, I can do that. I just recompiled it for bug #590.
>
> FYI: This is the API we are calling:
> http://api.libssh.org/stable/group__libssh__session.html#ga7a801b85800baa3f4e16f5b47db0a73d
>
> 2. in sshmasterconnection.cpp, we also set "SSH_OPTIONS_USER" . I think that we should also change its value from to.Ascii() to
> toLocal8Bit() or toUtf8(). bug566.test.v2.patch has this change for toLocal8Bit(), and bug566.utf8.test.patch has it for toUtf8().
>
> -Mike#2
>