#143432 adduser: does not correctly support NIS

Package:
adduser
Source:
adduser
Submitter:
Maik Busch
Date:
2026-07-30 08:33:02 UTC
Severity:
normal
Tags:
#143432#5
Date:
2002-04-18 13:04:32 UTC
From:
To:
Hello,

If I add a new user on my NIS server adduser run 'make -C /var/yp' twice,
first after adding the user, and second after adding the group.

But I think it must run a third time after changing the passwd for the user.
Without it is not possible to login on any client.

Maik

maik@obelix:~> su -
Password:
obelix:~# adduser hallo
Adding user hallo...
make: Entering directory `/var/yp'
make[1]: Entering directory `/var/yp/startrek'
make[1]: `ypservers' is up to date.
make[1]: Leaving directory `/var/yp/startrek'
make[1]: Entering directory `/var/yp/startrek'
Updating shadow.byname... Ignored -> merged with passwd
make[1]: Leaving directory `/var/yp/startrek'
make: Leaving directory `/var/yp'
Adding new user hallo (3259) with group arzt.
make: Entering directory `/var/yp'
make[1]: Entering directory `/var/yp/startrek'
make[1]: `ypservers' is up to date.
make[1]: Leaving directory `/var/yp/startrek'
make[1]: Entering directory `/var/yp/startrek'
Updating passwd.byname...
Updating passwd.byuid...
Updating shadow.byname... Ignored -> merged with passwd
make[1]: Leaving directory `/var/yp/startrek'
make: Leaving directory `/var/yp'
Creating home directory /home/h/hallo.
Copying files from /etc/skel
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
Changing the user information for hallo
Enter the new value, or press return for the default
        Full Name []: Maik Hallo
        Room Number []:
        Work Phone []:
        Home Phone []:
        Other []:
Is the information correct? [y/n] y
Creating /var/lib/samba-profile/hallo
Enter SAMBA password.
New SMB password:
Retype new SMB password:
Enter NETATALK password.
Enter NEW AFP password:
Enter NEW AFP password again:
afppasswd: updated password.
obelix:~# echo $?
0
obelix:~# make -C /var/yp
make: Entering directory `/var/yp'
make[1]: Entering directory `/var/yp/startrek'
make[1]: `ypservers' is up to date.
make[1]: Leaving directory `/var/yp/startrek'
make[1]: Entering directory `/var/yp/startrek'
Updating passwd.byname...
Updating passwd.byuid...
Updating shadow.byname... Ignored -> merged with passwd
make[1]: Leaving directory `/var/yp/startrek'
make: Leaving directory `/var/yp'
obelix:~#

#143432#10
Date:
2003-01-15 20:17:29 UTC
From:
To:
Hi,

I was about to file a new bug, then saw these two.  (Can they perhaps be
merged?)

My symptom: if I "adduser xyzpdq" on an NIS server, but give mismatched
passwords, then subsequent "adduser xyzpdq" attempts fail outright.

The problem is that NIS still has xyzpdq in
/var/yp/<domain>/passwd.byname, group.byname and passwd.byuid.  So
adduser needs to do a "cd /var/yp && make" if the passwords don't match,
or even if they do match, according to 143432.

If this is added, I think both bugs can be closed.  (These are pretty
old bugs...)  Maintainer: would you accept a patch which does this?

Zeen,

#143432#13
Date:
2003-01-15 20:17:29 UTC
From:
To:
Hi,

I was about to file a new bug, then saw these two.  (Can they perhaps be
merged?)

My symptom: if I "adduser xyzpdq" on an NIS server, but give mismatched
passwords, then subsequent "adduser xyzpdq" attempts fail outright.

The problem is that NIS still has xyzpdq in
/var/yp/<domain>/passwd.byname, group.byname and passwd.byuid.  So
adduser needs to do a "cd /var/yp && make" if the passwords don't match,
or even if they do match, according to 143432.

If this is added, I think both bugs can be closed.  (These are pretty
old bugs...)  Maintainer: would you accept a patch which does this?

Zeen,

#143432#18
Date:
2003-01-15 21:48:30 UTC
From:
To:
Adam C Powell IV wrote:

For this one, sure. Should be a one-line fix if I get you correctly.
I'll try to have a look at it ASAP (which means probably at the end of
the week). If you're interested in fixing this before, go ahead.

#143432#23
Date:
2004-03-24 08:02:46 UTC
From:
To:
Isn't this the job of the shadow tools that are used by adduser to do
the grunt work? How will your patch behave on a non-NIS system?

Greetings
Marc

#143432#26
Date:
2004-03-24 08:02:46 UTC
From:
To:
Isn't this the job of the shadow tools that are used by adduser to do
the grunt work? How will your patch behave on a non-NIS system?

Greetings
Marc

#143432#31
Date:
2004-03-24 10:32:40 UTC
From:
To:
Did you get around to look at it? I don't have any clue about NIS,
unfortunately.

Greetings
Marc

#143432#36
Date:
2022-07-06 14:37:53 UTC
From:
To:
Control: tags -1 wontfix
thanks

I'm tagging this 20 year old bug wontfix since the adduser team has
decided to not add support for directory services like NIS and LDAP,
constricting the package to handling _local_ system accounts as a policy
layer in Debian.

I apologize for not having this done any earlier.

The adduser.local mechanism as documented in the adduser(8) man page can
be used to issue any commands that might be needed to invalidate caches
and do other cleanup. It is also recommended to configure the client
library of those directory services to not attempt to write to the
directory service if useradd or other commands from the passwd package
are invoked.

Greetings
Marc

#143432#41
Date:
2022-07-06 14:37:53 UTC
From:
To:
Control: tags -1 wontfix
thanks

I'm tagging this 20 year old bug wontfix since the adduser team has
decided to not add support for directory services like NIS and LDAP,
constricting the package to handling _local_ system accounts as a policy
layer in Debian.

I apologize for not having this done any earlier.

The adduser.local mechanism as documented in the adduser(8) man page can
be used to issue any commands that might be needed to invalidate caches
and do other cleanup. It is also recommended to configure the client
library of those directory services to not attempt to write to the
directory service if useradd or other commands from the passwd package
are invoked.

Greetings
Marc

#143432#46
Date:
2026-07-30 08:31:13 UTC
From:
To:
Return