Architcecture for winbindd client character conversion.

simo idra at samba.org
Tue Aug 28 19:03:49 GMT 2007


On Tue, 2007-08-28 at 11:46 -0700, Jeremy Allison wrote:
> On Tue, Aug 28, 2007 at 12:34:18PM -0400, simo wrote:
> 
> > I think I get this perfectly well.
> 
> So you know how broken we are right now on any client locale <> uft8 ?
> And you're ok with this ?

No, WE are not broken, as we let user choose the unix charset, it's just
we choose the most popular and useful default.

> > The bug is in Ubuntu not using utf8 as their default locale or in Ubuntu
> > not setting unix charset = iso8859-1 in smb.conf
> 
> Just because Fedora does it right, doesn't give you the right to
> leave a bug for everyone else.


> > Yes and this is correct as winbind clients are local process, no
> > networking is involved and we assume unix charset _has_ to be set up
> > with the right value for your system if your system does not use utf8.
> 
> locale can be set per client.

Usually it is set per machine, if by client you mean machine we agree,
if by client you mean process, yes you can do that but you are on your
own.

> > No, it's not WE that break, it's THEM, the clients are broken, or the
> > sysadmin not competent, or the distribution has broken defaults.
> > It is the same if you use nss_ldap or nis, you have to use the right
> > locale.
> 
> Hmmm. All locales <> unix charset are broken huh ?

No, it is not setting the right unix charset == system locale that is
wrong. Thr only bug I can see is that we may have "auto" as default and
use the system locale by default, instead of using a fixed default.
This would be something reasonable, as it let users change the whole
system locale without worrying of changing smb.conf but supporting
*multiple* locales in winbindd is just wrong IMHO.

> This is not acceptable (IMHO). It's what we used to
> do in Samba 1.x days : "just set your character set
> parameter to that of your DOS clients. What is I have
> more than one DOS client character set ? You're screwed
> mate....."

Except, that we are not talking about network connections!!

Jeremy,

q: if you have your name in utf8 in /etc/passwd and you change your
login locale does things break?
a: YES
q: if your filenames are written with utf8 characters and you use a
different locale do things look funny?
a: YES

Locale is something that is meant to be set per system, not per session,
the fact that you can do insane things like changing the session locale
so that it is different from the system locale does not mean we have to
help it.

Or, are you proposing we remount the home directory in loopback via cifs
so that we can translate file names as well ?

Do you propose also that we write a filtering VFS backend that
manipulate the contents of the files where the user name may have been
stored so that all is consistent with the new $RANDOM locale and does
not break as well?

Do you see the road to madness in trying to support multiple locales per
system yet ?

> > But we can argue on this point if you want, but don't assume people do
> > not understand, people here simply do not agree with you, which is
> > different.
> 
> Nope, I still think you're not understanding how serious
> this bug is :-). That's 'cos it doesn't affect Red Hat
> systems :-).

Now Jeremy you are really pissing me off, the fact that Fedora or RedHat
has sane defaults does not mean I can't have an opinion on the matter or
that my opinion is cluttered. I don't give a *censored* about what's in
Fedora or RedHat when I work on Samba if there is any conflict between
them and Samba.
I may claim as well that, as you are using a broken distribution, your
opinion is flawed, but I don't do that cause I don't think you are
stupid and I don't want to piss you off.

I would agree with, and even welcome, a patch to implement unix charset
= auto and use that by default and determine at daemon startup what is
the current system locale. That would be a good patch and a better
default.
Cluttering winbindd code instead would be not IMO.

Simo.

-- 
Simo Sorce
Samba Team GPL Compliance Officer
email: idra at samba.org
http://samba.org



More information about the samba-technical mailing list