whither 1.00's "passwd -p ..." ?

Denis Vlasenko vda.linux at googlemail.com
Thu Jul 5 05:19:35 PDT 2007


On Wednesday 04 July 2007 20:14, Jim Freeman wrote:
> On Wed, Jul 04, 2007 at 03:13:38PM +0200, Denis Vlasenko wrote:
> > On 7/3/07, Jim Freeman <jfree at sovereign.org> wrote:
> > >busybox 1.00 (and other versions?) had a "-p" option to allow setting
> > >a user's password bypassing the interactive mode
> ...
> > >        # passwd -p **** blip
> > >        Setting password for blip
> > >        Password changed.
> > 
> > I just downloaded and built busybox 1.00. passwd does not have -p option 
> > there.
> 
> Yeesh - my (very) bad.  Looks like this was an in-house change
> (derivative of "useradd -p"), then re-tar'd with the same name
> so namewise it was indistinguishable from the upstream.
> Apologies!  (slinks away in search of brown paper bag ...)

No problem. If you need it, maybe make a diff of said changes and
send to list. You may be not alone with this password change
requirement.

> http://dns.solucorp.qc.ca/linuxconf/changes/changes-1.9r22.html
> has "-P" for from a pipe:
> 
> 	The passwd command supplied with Linuxconf has been enhanced
> 		...
> 		passwd -P user_account
> 			Change the password from a pipe
> 			echo new_passwd | passwd -P user_account
> 
> or BSD's "pw" looks like it will take it from a pipe:
> http://lists.freebsd.org/pipermail/freebsd-questions/2007-April/146507.html

piping password is indeed safe(r) since it is not visible in ps
(echo is sheel internal builtin and won't show up in ps either).
--
vda


More information about the busybox mailing list