[PATCH] improve checks on usernames V3.
Tito
farmatito at tiscali.it
Tue Aug 2 20:46:15 UTC 2011
On Tuesday 02 August 2011 22:16:18 Ralf Friedl wrote:
> Tito wrote:
> > Hi,
> > minor improvements vs. v2 patch:
> > 1) some more comments added.
> > 2) we now print the position of the illegal character.
> >
> > ...
> > /* We don't use isalnum as it will allow locale-specific non-ASCII */
> > /* letters in legacy 8-bit locales. *
> What is the problem with locale-specific characters?
Just that they are not portable so that e.g. "If using external authentication sources to verify user credentials,
you must establish whether these authentication sources also support multi-byte characters.
If multi-byte characters are not supported, you must specify usernames and passwords using ASCII characters"
(portable filename charset is recommended).
> I have used user and group names with UTF-8 characters and I didn't
> notice a problem so far.
This is of course possible and this feature is optional and
could be turned off if not needed, OTOH allowing chars
as . - $ : / in usernames may be problematic.
> GNU ls even adjusts the width of the user and group names properly for
> UTF-8 names, which would be useless if such names can't be created.
> (Side note, Busybox ls does not adjust the width and truncates at 8 bytes).
>
> Ralf
>
Ciao,
Tito
More information about the busybox
mailing list