Provided by: login_4.1.1-6ubuntu6_i386 bug

NOM

       login.defs - configuration de la suite des mots de passe cachés
       « shadow password »

DESCRIPTION

       Le fichier /etc/login.defs définit la configuration de la suite shadow
       password (mots de passe cachés) pour le système. Ce fichier est
       indispensable. Son absence n´empêchera pas le système de fonctionner,
       mais aura probablement des conséquences indésirables.

       Ce fichier est un fichier texte, dont chaque ligne décrit un paramètre
       de configuration. Les lignes consistent en un nom et une valeur,
       séparés par un espace. Les lignes blanches et les lignes de
       commentaires sont ignorées. Les commentaires commencent par un
       caractère « # », qui doit être le premier caractère non blanc de la
       ligne.

       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 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 value with 0x). The maximum value of the regular and long numeric
       parameters is machine-dependent.

       Les paramètres de configuration suivants sont fournis :

       CHFN_RESTRICT (string)
           This parameter specifies which values in the gecos field of the
           /etc/passwd file may be changed by regular users using the chfn
           program. It can be any combination of letters f, r, w, h, 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.

       CONSOLE_GROUPS (string)
           List of groups to add to the user´s supplementary group set when
           logging in on the console (as determined by the CONSOLE setting).
           Default is none.

           Use with caution - it is possible for users to gain permanent
           access to these groups, even when not logged in on the console.

       DEFAULT_HOME (boolean)
           Indicate if login is allowed if we can´t cd to the home directory.
           Default in no.

           If set to yes, the user will login in the root (/) directory if it
           is not possible to cd to her home directory.

       ENCRYPT_METHOD (string)
           This defines the system default encryption algorithm for encrypting
           passwords (if no algorithm are specified on the command line).

           It can take one of these values:

           ·   DES (default)

           ·   MD5

           ·   SHA256

           ·   SHA512

               Note: this parameter overrides the MD5_CRYPT_ENAB variable.

               Note: if you use PAM, it is recommended to set this variable
               consistently with the PAM modules configuration.

       ENV_HZ (string)
           If set, it will be used to define the HZ environment variable when
           a user login. The value must be preceded by HZ=. A common value on
           Linux is HZ=100.

           The HZ environment variable is only set when the user (the
           superuser) logs in with sulogin.

       ENV_PATH (string)
           If set, it will be used to define the PATH environment variable
           when a regular user login. The value can be preceded by PATH=, or a
           colon separated list of paths (for example /bin:/usr/bin). The
           default value is PATH=/bin:/usr/bin.

       ENV_SUPATH (string)
           If set, it will be used to define the PATH environment variable
           when the superuser login. The value can be preceded by PATH=, or a
           colon separated list of paths (for example
           /sbin:/bin:/usr/sbin:/usr/bin). The default value is
           PATH=/bin:/usr/bin.

       ERASECHAR (number)
           Terminal ERASE character (010 = backspace, 0177 = DEL).

           The value can be prefixed "0" for an octal value, or "0x" for an
           hexadecimal value.

       FAIL_DELAY (number)
           Delay in seconds before being allowed another attempt after a login
           failure.

       FAKE_SHELL (string)
           If set, login will execute this shell instead of the users´ shell
           specified in /etc/passwd.

       GID_MAX (number), GID_MIN (number)
           Range of group IDs used for the creation of regular groups by
           useradd, useradd, or newusers.

       HUSHLOGIN_FILE (string)
           If defined, this file can inhibit all the usual chatter during the
           login sequence. If a full pathname is specified, then hushed mode
           will be enabled if the user´s name or shell are found in the file.
           If not a full pathname, then hushed mode will be enabled if the
           file exists in the user´s home directory.

       KILLCHAR (number)
           Terminal KILL character (025 = CTRL/U).

           The value can be prefixed "0" for an octal value, or "0x" for an
           hexadecimal value.

       LOG_OK_LOGINS (boolean)
           Enable logging of successful logins.

       LOG_UNKFAIL_ENAB (boolean)
           Enable display of unknown usernames when login failures are
           recorded.

           Note: logging unknown usernames may be a security issue if an user
           enter her password instead of her login name.

       LOGIN_RETRIES (number)
           Maximum number of login retries in case of bad password.

           This will most likely be overriden by PAM, since the default
           pam_unix module has it´s own built in of 3 retries. However, this
           is a safe fallback in case you are using an authentication module
           that does not enforce PAM_MAXTRIES.

       LOGIN_TIMEOUT (number)
           Max time in seconds for login.

       MAIL_DIR (string)
           Répertoire d´attente des courriels (« mail spool directory »). Ce
           paramètre est nécessaire pour manipuler les boîtes à lettres
           lorsque le compte d´un utilisateur est modifié ou supprimé. S´il
           n´est pas spécifié, une valeur par défaut définie à la compilation
           est utilisée.

       MAIL_FILE (string)
           Defines the location of the users mail spool files relatively to
           their home directory.

       The MAIL_DIR and MAIL_FILE variables are used by useradd, usermod, and
       userdel to create, move, or delete the user´s mail spool.

       MAX_MEMBERS_PER_GROUP (number)
           Maximum members per group entry. When the maximum is reached, a new
           group entry (line) is started in /etc/group (with the same name,
           same password, and same GID).

           The default value is 0, meaning that there are no limits in the
           number of members in a group.

           This feature (split group) permits to limit the length of lines in
           the group file. This is useful to make sure that lines for NIS
           groups are not larger than 1024 characters.

           If you need to enforce such limit, you can use 25.

           Note: split groups may not be supported by all tools (even in the
           Shadow toolsuite. You should not use this variable unless you
           really need it.

       MD5_CRYPT_ENAB (boolean)
           Indicate if passwords must be encrypted using the MD5-based
           algorithm. If set to yes, new passwords will be encrypted using the
           MD5-based algorithm compatible with the one used by recent releases
           of FreeBSD. It supports passwords of unlimited length and longer
           salt strings. Set to no if you need to copy encrypted passwords to
           other systems which don´t understand the new algorithm. Default is
           no.

           This variable is superceded by the ENCRYPT_METHOD variable or by
           any command line option used to configure the encryption algorithm.

           This variable is deprecated. You should use ENCRYPT_METHOD.

           Note: if you use PAM, it is recommended to set this variable
           consistently with the PAM modules configuration.

       PASS_MAX_DAYS (number)
           Nombre maximum de jours de validité d´un mot de passe. Après cette
           durée, une modification du mot de passe est obligatoire. S´il n´est
           pas précisé, la valeur de -1 est utilisée (ce qui enlève toute
           restriction).

       PASS_MIN_DAYS (number)
           Nombre minimum de jours autorisé avant la modification d´un mot de
           passe. Toute tentative de modification du mot de passe avant cette
           durée est rejetée. S´il n´est pas précisé, la valeur de -1 est
           utilisée (ce qui enlève toute restriction).

       PASS_WARN_AGE (number)
           Nombre de jours durant lesquels l´utilisateur recevra un
           avertissement avant que son mot de passe n´arrive en fin de
           validité. Une valeur négative signifie qu´aucun avertissement n´est
           donné. S´il n´est pas précisé, aucun avertissement n´est donné.

       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.

       SHA_CRYPT_MIN_ROUNDS (number), SHA_CRYPT_MAX_ROUNDS (number)
           When ENCRYPT_METHOD is set to SHA256 or SHA512, this defines the
           number of SHA rounds used by the encryption algorithm by default
           (when the number of rounds is not specified on the command line).

           With a lot of rounds, it is more difficult to brute forcing the
           password. But note also that more CPU resources will be needed to
           authenticate users.

           If not specified, the libc will choose the default number of rounds
           (5000).

           The values must be inside the 1000-999999999 range.

           If only one of the SHA_CRYPT_MIN_ROUNDS or SHA_CRYPT_MAX_ROUNDS
           values is set, then this value will be used.

           If SHA_CRYPT_MIN_ROUNDS > SHA_CRYPT_MAX_ROUNDS, the highest value
           will be used.

       SULOG_FILE (string)
           If defined, all su activity is logged to this file.

       SU_NAME (string)
           If defined, the command name to display when running "su -". For
           example, if this is defined as "su" then a "ps" will display the
           command is "-su". If not defined, then "ps" would display the name
           of the shell actually being run, e.g. something like "-sh".

       SYS_GID_MAX (number), SYS_GID_MIN (number)
           Range of group IDs used for the creation of system groups by
           useradd, groupadd, or newusers.

       SYS_UID_MAX (number), SYS_UID_MIN (number)
           Range of user IDs used for the creation of system users by useradd
           or newusers.

       SYSLOG_SG_ENAB (boolean)
           Enable "syslog" logging of sg activity.

       SYSLOG_SU_ENAB (boolean)
           Enable "syslog" logging of su activity - in addition to sulog file
           logging.

       TTYGROUP (string), TTYPERM (string)
           The terminal permissions: the login tty will be owned by the
           TTYGROUP group, and the permissions will be set to TTYPERM.

           By default, the ownership of the terminal is set to the user´s
           primary group and the permissions are set to 0600.

           TTYGROUP can be either the name of a group or a numeric group
           identifier.

           If you have a write program which is "setgid" to a special group
           which owns the terminals, define TTYGROUP to the group number and
           TTYPERM to 0620. Otherwise leave TTYGROUP commented out and assign
           TTYPERM to either 622 or 600.

       TTYTYPE_FILE (string)
           If defined, file which maps tty line to TERM environment parameter.
           Each line of the file is in a format something like "vt100 tty01".

       UID_MAX (number), UID_MIN (number)
           Range of user IDs used for the creation of regular users by useradd
           or newusers.

       UMASK (number)
           Valeur d´initialisation du masque de permissions. S´il n´est pas
           précisé, le masque des permissions sera initialisé à 022.

       USERDEL_CMD (string)
           Si ce paramètre est défini, cette commande est exécutée lors de la
           suppression d´un utilisateur. Elle pourra supprimer toutes les
           tâches périodiques cron ou at, tous les travaux d´impression, etc.
           de l´utilisateur (qui sera fourni comme premier paramètre).

       USERGROUPS_ENAB (boolean)

CROSS REFERENCES

       The following cross references show which programs in the shadow
       password suite use which parameters.

       chfn
           CHFN_RESTRICT

       chgpasswd
           ENCRYPT_METHOD MAX_MEMBERS_PER_GROUP MD5_CRYPT_ENAB
           SHA_CRYPT_MAX_ROUNDS SHA_CRYPT_MIN_ROUNDS

       chpasswd
           ENCRYPT_METHOD MD5_CRYPT_ENAB SHA_CRYPT_MAX_ROUNDS
           SHA_CRYPT_MIN_ROUNDS

       gpasswd
           ENCRYPT_METHOD MAX_MEMBERS_PER_GROUP MD5_CRYPT_ENAB
           SHA_CRYPT_MAX_ROUNDS SHA_CRYPT_MIN_ROUNDS

       groupadd
           GID_MAX GID_MIN MAX_MEMBERS_PER_GROUP SYS_GID_MAX SYS_GID_MIN

       groupdel
           MAX_MEMBERS_PER_GROUP

       groupmems
           MAX_MEMBERS_PER_GROUP

       groupmod
           MAX_MEMBERS_PER_GROUP

       grpck
           MAX_MEMBERS_PER_GROUP

       grpconv
           MAX_MEMBERS_PER_GROUP

       grpunconv
           MAX_MEMBERS_PER_GROUP

       login
           CONSOLE_GROUPS DEFAULT_HOME ERASECHAR FAIL_DELAY FAKE_SHELL
           HUSHLOGIN_FILE KILLCHAR LOGIN_RETRIES LOGIN_TIMEOUT LOG_OK_LOGINS
           LOG_UNKFAIL_ENAB TTYGROUP TTYPERM TTYTYPE_FILE USERGROUPS_ENAB

       newgrp
           SYSLOG_SG_ENAB

       newusers
           ENCRYPT_METHOD GID_MAX GID_MIN MAX_MEMBERS_PER_GROUP MD5_CRYPT_ENAB
           PASS_MAX_DAYS PASS_MIN_DAYS PASS_WARN_AGE SHA_CRYPT_MAX_ROUNDS
           SHA_CRYPT_MIN_ROUNDS SYS_GID_MAX SYS_GID_MIN SYS_UID_MAX
           SYS_UID_MIN UID_MAX UID_MIN UMASK

       pwck
           PASS_MAX_DAYS PASS_MIN_DAYS PASS_WARN_AGE

       pwconv
           PASS_MAX_DAYS PASS_MIN_DAYS PASS_WARN_AGE

       su
           CONSOLE_GROUPS DEFAULT_HOME ENV_PATH ENV_SUPATH SULOG_FILE SU_NAME
           SYSLOG_SU_ENAB

       sulogin
           ENV_HZ

       useradd
           GID_MAX GID_MIN MAIL_DIR MAX_MEMBERS_PER_GROUP PASS_MAX_DAYS
           PASS_MIN_DAYS PASS_WARN_AGE SYS_GID_MAX SYS_GID_MIN SYS_UID_MAX
           SYS_UID_MIN UID_MAX UID_MIN UMASK

       userdel
           MAIL_DIR MAIL_FILE MAX_MEMBERS_PER_GROUP USERDEL_CMD
           USERGROUPS_ENAB

       usermod
           MAIL_DIR MAIL_FILE MAX_MEMBERS_PER_GROUP

       vipw
           MAX_MEMBERS_PER_GROUP

BOGUES

       La plupart des fonctionnalités qui étaient fournies par les mots de
       passe cachés (« shadow password ») sont désormais gérées par PAM. De ce
       fait, /etc/login.defs n´est plus utilisé par les programmes tels que
       login(1), passwd(1) et su(1). Veuillez plutôt vous référer aux fichiers
       de configuration de PAM correspondant.

VOIR AUSSI

       login(1), passwd(1), su(1), passwd(5), shadow(5), pam(8).