tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: getpwent and duplicate names in /etc/master.passwd



On Sun, 24 Jun 2012, David Holland wrote:

On Sun, Jun 24, 2012 at 09:03:27PM +0200, Jean-Yves Migeon wrote:
> > Hi all,
> > while looking at the code for getpwent, I stumbled across an
> > inconsistency in the behavior of pwd_mkdb. If /etc/master.passwd
> > contains a duplicate name (e.g. two lines for root), this is preserved
> > in spwd.db, but not in /etc/passwd. Is there any reason for such
> > behavior? Should pwd_mkdb reject installing the password file in first
> > place?
>
> I think it should reject the creation.
>
> How can it happen in the first place unless by tweaking master.passwd by
> hand anyway? This should be discouraged...

spl0its?

I think it should fail, yes.

We're not supposed to edit the password file by hand?

--
Hisashi T Fujinaka - htodd%twofifty.com@localhost
BSEE(6/86) + BSChem(3/95) + BAEnglish(8/95) + MSCS(8/03) + $2.50 = latte


Home | Main Index | Thread Index | Old Index