2007-10-07 17:16:16 +05:30
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
|
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
|
|
|
|
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
|
|
|
|
<refentry id='login.defs.5'>
|
2007-10-07 17:17:22 +05:30
|
|
|
<!-- $Id: login.defs.5.xml,v 1.16 2006/03/07 15:47:32 kloczek Exp $ -->
|
2007-10-07 17:16:16 +05:30
|
|
|
<refmeta>
|
|
|
|
<refentrytitle>login.defs</refentrytitle>
|
|
|
|
<manvolnum>5</manvolnum>
|
2007-10-07 17:17:11 +05:30
|
|
|
<refmiscinfo class="sectdesc">File Formats and Conversions</refmiscinfo>
|
2007-10-07 17:16:16 +05:30
|
|
|
</refmeta>
|
|
|
|
<refnamediv id='name'>
|
2007-10-07 17:16:25 +05:30
|
|
|
<refname>login.defs</refname>
|
2007-10-07 17:16:16 +05:30
|
|
|
<refpurpose>shadow password suite configuration</refpurpose>
|
|
|
|
</refnamediv>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
2007-10-07 17:16:16 +05:30
|
|
|
<refsect1 id='description'>
|
|
|
|
<title>DESCRIPTION</title>
|
2007-10-07 17:17:01 +05:30
|
|
|
<para>
|
|
|
|
The <filename>/etc/login.defs</filename> file defines the
|
2007-10-07 17:16:16 +05:30
|
|
|
site-specific configuration for the shadow password suite. This file
|
|
|
|
is required. Absence of this file will not prevent system operation,
|
|
|
|
but will probably result in undesirable operation.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
|
|
|
<para>
|
|
|
|
This file is a readable text file, each line of the file describing
|
|
|
|
one configuration parameter. The lines consist of a configuration name
|
|
|
|
and value, separated by whitespace. Blank lines and comment lines are
|
|
|
|
ignored. Comments are introduced with a `#' pound sign and the pound
|
|
|
|
sign must be the first non-white character of the line.
|
2007-10-07 17:16:16 +05:30
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
|
|
|
<para>
|
|
|
|
Parameter values may be of four types: strings, booleans, numbers, and
|
|
|
|
long numbers. A string is comprised of any printable characters. A
|
|
|
|
boolean should be either the value “yes” or
|
2007-10-07 17:16:16 +05:30
|
|
|
“no”. An undefined boolean parameter or one with a value
|
|
|
|
other than these will be given a “no” value. Numbers (both
|
|
|
|
regular and long) may be either decimal values, octal values (precede
|
|
|
|
the value with “0”) or hexadecimal values (precede the
|
2007-10-07 17:16:25 +05:30
|
|
|
value with “0x”). The maximum value of the regular and
|
2007-10-07 17:16:16 +05:30
|
|
|
long numeric parameters is machine-dependent.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
2007-10-07 17:16:16 +05:30
|
|
|
<para>The following configuration items are provided:</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
2007-10-07 17:16:16 +05:30
|
|
|
<variablelist remap='IP'>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>CHFN_AUTH (boolean)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
If <emphasis remap='I'>yes</emphasis>, the
|
|
|
|
<command>chfn</command> and <command>chsh</command> programs
|
|
|
|
will require authentication before making any changes, unless
|
|
|
|
run by the superuser.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>CHFN_RESTRICT (string)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
This parameter specifies which values in the <emphasis
|
|
|
|
remap='I'>gecos</emphasis> field of the
|
|
|
|
<filename>/etc/passwd</filename> file may be changed by regular
|
|
|
|
users using the <command>chfn</command> program. It can be any
|
|
|
|
combination of letters <emphasis remap='I'>f</emphasis>
|
|
|
|
,<emphasis remap='I'>r</emphasis>, <emphasis remap='I'>w</emphasis>,
|
|
|
|
<emphasis remap='I'>h</emphasis>, for Full name, Room number,
|
|
|
|
Work phone, and Home phone, respectively. For backward
|
|
|
|
compatibility, "yes" is equivalent to "rwh" and "no" is
|
|
|
|
equivalent to "frwh". If not specified, only the superuser can
|
|
|
|
make any changes. The most restrictive setting is better
|
|
|
|
achieved by not installing chfn SUID.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>CREATE_HOME (boolean)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
This defines whether useradd should create home directories for
|
|
|
|
users by default. This option is OR'ed with the
|
|
|
|
<option>-m</option> flag on useradd command line.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>GID_MAX (number)</term>
|
|
|
|
<term>GID_MIN (number)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
Range of group IDs to choose from for the
|
|
|
|
<command>useradd</command> and <command>groupadd</command>
|
|
|
|
programs.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>MAIL_DIR (string)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
The mail spool directory. This is needed to manipulate the
|
|
|
|
mailbox when its corresponding user account is modified or
|
|
|
|
deleted. If not specified, a compile-time default is used.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>PASS_MAX_DAYS (number)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
The maximum number of days a password may be used. If the
|
|
|
|
password is older than this, a password change will be forced.
|
|
|
|
If not specified, -1 will be assumed (which disables the
|
|
|
|
restriction).
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>PASS_MIN_DAYS (number)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
The minimum number of days allowed between password changes.
|
|
|
|
Any password changes attempted sooner than this will be
|
|
|
|
rejected. If not specified, -1 will be assumed (which disables
|
|
|
|
the restriction).
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>PASS_WARN_AGE (number)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
The number of days warning given before a password expires. A
|
|
|
|
zero means warning is given only upon the day of expiration, a
|
|
|
|
negative value means no warning is given. If not specified, no
|
|
|
|
warning will be provided.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
|
|
|
<para>
|
|
|
|
PASS_MAX_DAYS, PASS_MIN_DAYS and PASS_WARN_AGE are only used at the
|
|
|
|
time of account creation. Any changes to these settings won't affect
|
|
|
|
existing accounts.
|
2007-10-07 17:16:16 +05:30
|
|
|
</para>
|
|
|
|
<variablelist remap='IP'>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>UID_MAX (number)</term>
|
|
|
|
<term>UID_MIN (number)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
Range of user IDs to choose from for the
|
|
|
|
<command>useradd</command> program.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>UMASK (number)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
The permission mask is initialized to this value. If not
|
2007-10-07 17:17:22 +05:30
|
|
|
specified, the permission mask will be initialized to 022.
|
2007-10-07 17:17:01 +05:30
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>USERDEL_CMD (string)</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
If defined, this command is run when removing a user. It should
|
|
|
|
remove any at/cron/print jobs etc. owned by the user to be
|
|
|
|
removed (passed as the first argument).
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
|
|
</refsect1>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
2007-10-07 17:16:16 +05:30
|
|
|
<refsect1 id='cross_reference'>
|
|
|
|
<title>CROSS REFERENCE</title>
|
2007-10-07 17:17:01 +05:30
|
|
|
<para>
|
|
|
|
The following cross reference shows which programs in the shadow
|
2007-10-07 17:16:16 +05:30
|
|
|
password suite use which parameters.
|
|
|
|
</para>
|
|
|
|
<!-- .na -->
|
|
|
|
<variablelist remap='IP'>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>chfn</term>
|
|
|
|
<listitem>
|
|
|
|
<para>CHFN_AUTH CHFN_RESTRICT</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>chsh</term>
|
|
|
|
<listitem>
|
|
|
|
<para>CHFN_AUTH</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>groupadd</term>
|
|
|
|
<listitem>
|
|
|
|
<para>GID_MAX GID_MIN</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>newusers</term>
|
|
|
|
<listitem>
|
|
|
|
<para>PASS_MAX_DAYS PASS_MIN_DAYS PASS_WARN_AGE
|
|
|
|
UMASK
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>pwconv</term>
|
|
|
|
<listitem>
|
|
|
|
<para>PASS_MAX_DAYS PASS_MIN_DAYS PASS_WARN_AGE</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>useradd</term>
|
|
|
|
<listitem>
|
|
|
|
<para>CREATE_HOME
|
|
|
|
GID_MAX GID_MIN
|
|
|
|
PASS_MAX_DAYS PASS_MIN_DAYS PASS_WARN_AGE
|
|
|
|
UID_MAX UID_MIN
|
|
|
|
UMASK
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>userdel</term>
|
|
|
|
<listitem>
|
|
|
|
<para>MAIL_DIR
|
|
|
|
USERDEL_CMD
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>usermod</term>
|
|
|
|
<listitem>
|
|
|
|
<para>MAIL_DIR</para>
|
|
|
|
<!-- .ad -->
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
</variablelist>
|
|
|
|
</refsect1>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
2007-10-07 17:16:16 +05:30
|
|
|
<refsect1 id='bugs'>
|
|
|
|
<title>BUGS</title>
|
2007-10-07 17:17:01 +05:30
|
|
|
<para>
|
|
|
|
Much of the functionality that used to be provided by the shadow
|
2007-10-07 17:16:16 +05:30
|
|
|
password suite is now handled by PAM. Thus,
|
|
|
|
<filename>/etc/login.defs</filename> is no longer used by programs
|
2007-10-07 17:17:01 +05:30
|
|
|
such as: <citerefentry>
|
|
|
|
<refentrytitle>login</refentrytitle><manvolnum>1</manvolnum>
|
|
|
|
</citerefentry>, <citerefentry>
|
|
|
|
<refentrytitle>passwd</refentrytitle><manvolnum>1</manvolnum>
|
|
|
|
</citerefentry>, <citerefentry>
|
|
|
|
<refentrytitle>su</refentrytitle><manvolnum>1</manvolnum>
|
|
|
|
</citerefentry>. Please refer to the corresponding PAM configuration
|
|
|
|
files instead.
|
2007-10-07 17:16:16 +05:30
|
|
|
</para>
|
|
|
|
</refsect1>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
2007-10-07 17:16:16 +05:30
|
|
|
<refsect1 id='see_also'>
|
|
|
|
<title>SEE ALSO</title>
|
2007-10-07 17:17:01 +05:30
|
|
|
<para>
|
|
|
|
<citerefentry>
|
|
|
|
<refentrytitle>login</refentrytitle><manvolnum>1</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>passwd</refentrytitle><manvolnum>1</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>su</refentrytitle><manvolnum>1</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>passwd</refentrytitle><manvolnum>5</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>shadow</refentrytitle><manvolnum>5</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>pam</refentrytitle><manvolnum>8</manvolnum>
|
|
|
|
</citerefentry>.
|
2007-10-07 17:16:16 +05:30
|
|
|
</para>
|
|
|
|
</refsect1>
|
|
|
|
</refentry>
|