[Pkg-shadow-devel] Bug#136116: passwd: pwconv goes into infinite loop on duplicate userids
Nicolas François
Nicolas François , 136116@bugs.debian.org
Wed, 30 Mar 2005 22:36:08 +0200
retitle 136116 [POST-SARGE] passwd: pwconv goes into infinite loop on duplicate userids
thanks
Hi,
On Wed, Feb 27, 2002 at 11:28:00PM +0000, Paul Martin wrote:
> Run pwunconv.
>
> Edit /etc/passwd, and duplicate any line in there. (This simulates a
> mistake in a maintenance script.)
>
> Run pwconv.
>
> Notice how it runs forever, rather than throwing out an error?
The current pwconv man page mentions:
BUGS
Errors in the password or group files (such as invalid or duplicate
entries) may cause these programs to loop forever or fail in other
strange ways. Please run pwck and grpck to correct any such errors
before converting to or from shadow passwords or groups.
(Maybe this was added after this bug report)
It would be nice if pwck (or grpck) were run before running
pwconv/pwunconv (or grpconv/grpunconv).
I propose to make move pwconv to pwconv-nocheck, and make a /bin/pwconv
shell script which would call pwck and pwconv-nocheck. pwconv-nocheck
could still be used in non-interactive scripts.
Best Regards,
--
Nekral