ADDUSER(8) BSD System Manager's Manual ADDUSER(8)
adduser - create new users with a text-driven menu interface
adduser
The adduser utility creates a user with a group whose name and GID correspond to the user's name and UID, and populates his home directory with the contents of /etc/skel. The user is by default put into the login class "default", has no password timeouts, secondary groups, or other special options. To change the login class, use the following command: $ sudo vipw To add a user to a secondary group or remove him from any groups, or to add not yet existing groups, use the following command: $ sudoedit /etc/group Users and groups are never removed. To disable a user, change his login class to default (empty field), his home directory to /nonexistant, and his shell to /sbin/nologin. Remove his former home directory and set the password so that the user cannot login any more (only an asterisk), but do not delete the entry.
ed(1), mksh(1), passwd(1), group(5), login.conf(5), passwd(5), nologin(8), sudo(8), vipw(8)
adduser first appeared in MirBSD #10.
adduser was written by Thorsten Glaser <tg@mirbsd.de>.
MirBSD #8 and previous had a complex user-management suite mixed from shell, perl, and C code, with an added advertising clause, and many more unneeded functions. It is recommended to never delete users and groups, just disable them, anyway, so that the UIDs and GIDs will not be reused. This utility scans for collisions with both UIDs and GIDs, so that, in practice, retaining the group is enough. Changing the login class or group memberships of a user, as well as group management, must be done manually by using vipw and editing /etc/group, respectively. This is actually by design. To make an S/Key- or SSH public key only user account, set his password field to the string "skey" using vipw, or use an empty password and answer "no" when asked if the user should be prevented from logging in, to prevent the daily cron job's security checks from complaining. MirBSD #10-current June 25, 2008 1