.\"
.\" $FreeBSD$
.\"
-.Dd March 30, 2004
+.Dd September 15, 2012
.Dt ADDUSER 8
.Os
.Sh NAME
.Op Fl CDENShq
.Op Fl G Ar groups
.Op Fl L Ar login_class
+.Op Fl M Ar mode
.Op Fl d Ar partition
.Op Fl f Ar file
.Op Fl g Ar login_group
.Xr pw 8
will accept.
Generally this means it
-may contain only lowercase characters or digits.
+may contain only lowercase characters or digits but cannot begin with the
+.Ql -
+character.
Maximum length
is 16 characters.
The reasons for this limit are historical.
and recompile the
world; people have done this and it works, but you will have problems
with any precompiled programs, or source that assumes the 8-character
-name limit and NIS.
+name limit, such as NIS.
The NIS protocol mandates an 8-character username.
If you need a longer login name for e-mail addresses,
you can define an alias in
and create files in their home directory
without worrying about others being able to change them.
.Pp
-For a shared area you create a separate UID/GID (like cvs or ncvs on freefall),
-you place each person that should be able to access this area into that new
-group.
+For a shared area you create a separate UID/GID, you place each person
+that should be able to access this area into that new group.
.Pp
This model of UID/GID administration allows far greater flexibility than lumping
users into groups and having to muck with the umask when working in a shared
The format
of the input file is described below.
.It Fl g Ar login_group
-Normaly,
+Normally,
if no login group is specified,
it is assumed to be the same as the username.
This option makes
.Ar login_group
the default.
.It Fl G Ar groups
-Additional groups.
+Space-separated list of additional groups.
This option allows the user to specify additional groups to add users to.
The user is a member of these groups in addition to their login group.
.It Fl h
file can reference the internal variables of the
.Nm
script.
+.It Fl M Ar mode
+Create the home directory with permissions set to
+.Ar mode .
.It Fl N
Do not read the default configuration file.
.It Fl q
empty, its contents will be used
as a password.
This field will be ignored if the
-.Fl p
+.Fl w
option is used with a
.Cm no
or
.Sh AUTHORS
.An -nosplit
This manual page and the original script, in Perl, was written by
-.An Wolfram Schneider Aq wosch@FreeBSD.org .
+.An Wolfram Schneider Aq Mt wosch@FreeBSD.org .
The replacement script, written as a Bourne
shell script with some enhancements, and the man page modification that
came with it were done by
-.An Mike Makonnen Aq mtm@identd.net .
+.An Mike Makonnen Aq Mt mtm@identd.net .
.Sh BUGS
In order for
.Nm
The
.Nm
utility attempts to mitigate the possibility of an attacker using this
-feature by refusing to evaluate the file if it is not owned and writeable
+feature by refusing to evaluate the file if it is not owned and writable
only by the root user.
In addition, shell special characters and operators will have to be
escaped when used in the message file.
.Pp
-Also, password ageing and account expiry times are currently setable
+Also, password ageing and account expiry times are currently settable
only in batch mode or when specified in
.Pa /etc/adduser.conf .
The user should be able to set them in interactive mode as well.