Re: International characters in username/password
Jeff Layton <[email protected]> Thu, 22 Apr 2010 08:28:48 -0400
| Newsgroups | gmane.linux.file-systems.cifs |
|---|---|
| Message-ID | <[email protected]> |
On Thu, 22 Apr 2010 10:58:03 +0100 Alex Zeffertt <[email protected]> wrote: > Hi all, > > Does anybody know how to get "mount.cifs -ocredentials=path/to/file" to work > when there are international characters in the credentials file? > > I tested this with a password containing the £ (British pound) sign and I got > the following error: > > mount error 13 = Permission denied > Refer to the mount.cifs(8) manual page (e.g.man mount.cifs) > > The credentials file appears to be UTF-8, with all the characters one byte wide > except for the "£" sign which is encoded as "0xc2 0xa3". > > I am using samba-client-3.0.33-3.15.el5_4.1 with linux-2.6.27 and Windows 2003 > Server to host the share. > > Regards, > > Alex > _______________________________________________ > linux-cifs-client mailing list > [email protected] > https://lists.samba.org/mailman/listinfo/linux-cifs-client > mount.cifs and the kernel both pretty much treat the password as an opaque sequence of bytes and don't really care what character set they're in. The exception would be if you had a character with a NULL byte embedded in it, which would probably trick them into truncating the password. That doesn't sound like it's the case here. I think it's likely that the kernel routine that generates the NTLM hashes in fs/cifs/smbencrypt.c is broken with respect to multibyte characters. It seems to expect ASCII passwords, but I don't 100% understand what it's doing at the moment. All of that code is in desperate need of overhaul anyway to make NTLMSSP work, and really needs to be fixed so that it uses the kernel crypto and NLS routines instead its own routines. Unless you're willing to tackle this project yourself, please open a bug at bugzilla.samba.org so that we don't lose track of this. If you do that, please cc me on the bug and I'll plan to grab it. Thanks, -- Jeff Layton <[email protected]> _______________________________________________ linux-cifs-client mailing list [email protected] https://lists.samba.org/mailman/listinfo/linux-cifs-client