[Samba] CIFS mount with non-ascii (UTF8) password is not working

Moray Henderson Moray.Henderson at ict-software.org
Fri Mar 25 04:44:42 MDT 2011


Katariya Rahul wrote:
> I have French CIFS server.
> 
> If I try to map a share from any windows machine with non-ascii (UTF-8,
> french characters are part of password) password, it is successful.
> 
> But If I try from linux machine, it fails.
> 
> mount -t cifs //MACHINE/DatasetFIGS_ùÉÀÊÚÎÏŒÄÑ£₣€  /tmp/rahul -o
> user=ùù,password=ùù,domain=eKKDr
> mount error 13 = Permission denied
> Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)
>  
> 
> Does CIFS supports non-ascii password?

On the Linux machine, what output does the "locale" command give you?

If you type the password at the Linux prompt where you can see it, do you get the right characters?  If the keyboard isn't set right in Linux, it won't work.  To see exactly how the password is being encoded, use "echo <password> | xxd" (although obviously don't post the output for a real password here).

Was the password set from Windows or from Linux?  If from Windows, then I would expect the encoding to be in either UTF-16 or the Windows locale 8-bit encoding, not UTF-8.  For example, "Latin Small Letter E With Acute" is encoded as 0xE9 in the Windows Western encoding, 0xE900 in UTF-16, and 0xC3A9 in UTF-8.

Does it work any better if you use Samba's own mount.cifs program directly rather than going through mount?

I do not know what (if any) character encoding translation the cifs module does.  Check whether the locale and "testparm -vs | grep char" on your CIFS server match the settings on the Linux machine you are doing the mapping from.



Moray.
“To err is human; to purr, feline.”






More information about the samba mailing list