adduser/passwd: too long username

Denys Vlasenko vda.linux at googlemail.com
Tue Aug 5 18:16:04 UTC 2014


On Mon, Aug 4, 2014 at 7:06 PM, Laszlo Papp <lpapp at kde.org> wrote:
> sudo busybox adduser
> fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
> passwd: unknown user
> fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
>
> Yet, the user is created in /etc/shadow:
>
> fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff:!:16286:0:99999:7:::
>
> This is at least one issue, but there is another here:
>
> sudo busybox deluser
> fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
> deluser: unknown user
> fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff

Both issues come from the same location in codebase:
bb__pgsreader() parser drops lines which are longer than its buffer.

Effectively, bbox ignores offending line in /etc/passwd.

> Could you please look into this and potentially fix it? Thanks in advance.

Anyone willing to rewrite getpwnam API to use variable-sized malloced buffer?


More information about the busybox mailing list