2007-10-07 17:16:16 +05:30
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
2008-10-11 17:14:43 +05:30
|
|
|
<!--
|
2021-12-05 21:05:27 +05:30
|
|
|
SPDX-FileCopyrightText: 1991 - 1994, Julianne Frances Haugh
|
|
|
|
SPDX-FileCopyrightText: 2007 - 2011, Nicolas François
|
|
|
|
SPDX-License-Identifier: BSD-3-Clause
|
2008-10-11 17:14:43 +05:30
|
|
|
-->
|
* man/login.defs.d/CONSOLE_GROUPS.xml,
man/login.defs.d/CONSOLE.xml, man/login.defs.d/DEFAULT_HOME.xml,
man/login.defs.d/ENV_HZ.xml, man/login.defs.d/ENVIRON_FILE.xml,
man/login.defs.d/ENV_PATH.xml, man/login.defs.d/ENV_SUPATH.xml,
man/login.defs.d/ENV_TZ.xml, man/login.defs.d/ERASECHAR.xml,
man/login.defs.d/FAIL_DELAY.xml,
man/login.defs.d/FAILLOG_ENAB.xml,
man/login.defs.d/FAKE_SHELL.xml, man/login.defs.d/FTMP_FILE.xml,
man/login.defs.d/HUSHLOGIN_FILE.xml,
man/login.defs.d/ISSUE_FILE.xml, man/login.defs.d/KILLCHAR.xml,
man/login.defs.d/LASTLOG_ENAB.xml, man/login.defs.d/LOGIN_RETRIES.xml,
man/login.defs.d/LOGIN_TIMEOUT.xml, man/login.defs.d/LOG_OK_LOGINS.xml,
man/login.defs.d/LOG_UNKFAIL_ENAB.xml,
man/login.defs.d/MAIL_CHECK_ENAB.xml, man/login.defs.d/MOTD_FILE.xml,
man/login.defs.d/NOLOGINS_FILE.xml,
man/login.defs.d/OBSCURE_CHECKS_ENAB.xml,
man/login.defs.d/PASS_ALWAYS_WARN.xml,
man/login.defs.d/PASS_CHANGE_TRIES.xml,
man/login.defs.d/PASS_MAX_LEN.xml,
man/login.defs.d/PORTTIME_CHECKS_ENAB.xml,
man/login.defs.d/QUOTAS_ENAB.xml, man/login.defs.d/SULOG_FILE.xml,
man/login.defs.d/SU_NAME.xml, man/login.defs.d/SU_WHEEL_ONLY.xml,
man/login.defs.d/SYSLOG_SG_ENAB.xml,
man/login.defs.d/SYSLOG_SU_ENAB.xml,
man/login.defs.d/TTYGROUP.xml, man/login.defs.d/TTYTYPE_FILE.xml,
man/login.defs.d/ULIMIT.xml, man/login.defs.d/USERGROUPS_ENAB.xml:
New documentation of login.defs variables.
* man/login.defs.d/MAIL_DIR.xml: Updated. It now contains the
MAIL_FILE documentation.
* man/login.defs.d/LOGIN_STRING.xml: Updated. Mentions %s.
* man/pwconv.8.xml, man/groupmems.8.xml, man/groupdel.8.xml,
man/useradd.8.xml, man/pwck.8.xml, man/groupadd.8.xml,
man/sulogin.8.xml, man/newgrp.1.xml, man/usermod.8.xml,
man/su.1.xml, man/vipw.8.xml, man/passwd.1.xml,
man/groupmod.8.xml, man/login.1.xml, man/userdel.8.xml,
man/grpck.8.xml: Added CONFIGURATION section.
* man/generate_mans.mak: The generations of manpages depends on
the variables from the Makefiles. Add the dependency on Makefile.
* man/login.defs.5.xml: New login.defs variable documented.
* man/Makefile.am: Added XML variable documentation to the
distributed files.
2007-12-09 04:54:40 +05:30
|
|
|
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.5//EN"
|
|
|
|
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
2018-11-28 19:27:16 +05:30
|
|
|
<!ENTITY LASTLOG_UID_MAX SYSTEM "login.defs.d/LASTLOG_UID_MAX.xml">
|
* man/login.defs.d/CONSOLE_GROUPS.xml,
man/login.defs.d/CONSOLE.xml, man/login.defs.d/DEFAULT_HOME.xml,
man/login.defs.d/ENV_HZ.xml, man/login.defs.d/ENVIRON_FILE.xml,
man/login.defs.d/ENV_PATH.xml, man/login.defs.d/ENV_SUPATH.xml,
man/login.defs.d/ENV_TZ.xml, man/login.defs.d/ERASECHAR.xml,
man/login.defs.d/FAIL_DELAY.xml,
man/login.defs.d/FAILLOG_ENAB.xml,
man/login.defs.d/FAKE_SHELL.xml, man/login.defs.d/FTMP_FILE.xml,
man/login.defs.d/HUSHLOGIN_FILE.xml,
man/login.defs.d/ISSUE_FILE.xml, man/login.defs.d/KILLCHAR.xml,
man/login.defs.d/LASTLOG_ENAB.xml, man/login.defs.d/LOGIN_RETRIES.xml,
man/login.defs.d/LOGIN_TIMEOUT.xml, man/login.defs.d/LOG_OK_LOGINS.xml,
man/login.defs.d/LOG_UNKFAIL_ENAB.xml,
man/login.defs.d/MAIL_CHECK_ENAB.xml, man/login.defs.d/MOTD_FILE.xml,
man/login.defs.d/NOLOGINS_FILE.xml,
man/login.defs.d/OBSCURE_CHECKS_ENAB.xml,
man/login.defs.d/PASS_ALWAYS_WARN.xml,
man/login.defs.d/PASS_CHANGE_TRIES.xml,
man/login.defs.d/PASS_MAX_LEN.xml,
man/login.defs.d/PORTTIME_CHECKS_ENAB.xml,
man/login.defs.d/QUOTAS_ENAB.xml, man/login.defs.d/SULOG_FILE.xml,
man/login.defs.d/SU_NAME.xml, man/login.defs.d/SU_WHEEL_ONLY.xml,
man/login.defs.d/SYSLOG_SG_ENAB.xml,
man/login.defs.d/SYSLOG_SU_ENAB.xml,
man/login.defs.d/TTYGROUP.xml, man/login.defs.d/TTYTYPE_FILE.xml,
man/login.defs.d/ULIMIT.xml, man/login.defs.d/USERGROUPS_ENAB.xml:
New documentation of login.defs variables.
* man/login.defs.d/MAIL_DIR.xml: Updated. It now contains the
MAIL_FILE documentation.
* man/login.defs.d/LOGIN_STRING.xml: Updated. Mentions %s.
* man/pwconv.8.xml, man/groupmems.8.xml, man/groupdel.8.xml,
man/useradd.8.xml, man/pwck.8.xml, man/groupadd.8.xml,
man/sulogin.8.xml, man/newgrp.1.xml, man/usermod.8.xml,
man/su.1.xml, man/vipw.8.xml, man/passwd.1.xml,
man/groupmod.8.xml, man/login.1.xml, man/userdel.8.xml,
man/grpck.8.xml: Added CONFIGURATION section.
* man/generate_mans.mak: The generations of manpages depends on
the variables from the Makefiles. Add the dependency on Makefile.
* man/login.defs.5.xml: New login.defs variable documented.
* man/Makefile.am: Added XML variable documentation to the
distributed files.
2007-12-09 04:54:40 +05:30
|
|
|
<!ENTITY MAIL_DIR SYSTEM "login.defs.d/MAIL_DIR.xml">
|
|
|
|
<!ENTITY MAX_MEMBERS_PER_GROUP SYSTEM "login.defs.d/MAX_MEMBERS_PER_GROUP.xml">
|
2013-08-11 19:35:26 +05:30
|
|
|
<!ENTITY SUB_GID_COUNT SYSTEM "login.defs.d/SUB_GID_COUNT.xml">
|
|
|
|
<!ENTITY SUB_UID_COUNT SYSTEM "login.defs.d/SUB_UID_COUNT.xml">
|
* man/chage.1.xml, man/login.defs.5.xml, man/pwck.8.xml,
man/pwconv.8.xml, man/useradd.8.xml, man/userdel.8.xml,
man/usermod.8.xml, man/vipw.8.xml: Document the usage of the
TCB_AUTH_GROUP, TCB_SYMLINKS, and USE_TCB configuration
parameters.
* man/pwconv.8.xml, man/pwck.8.xml: Document the behavior when
USE_TCB is enabled.
2010-03-17 00:45:05 +05:30
|
|
|
<!ENTITY TCB_SYMLINKS SYSTEM "login.defs.d/TCB_SYMLINKS.xml">
|
|
|
|
<!ENTITY USE_TCB SYSTEM "login.defs.d/USE_TCB.xml">
|
2011-07-09 01:19:09 +05:30
|
|
|
<!-- SHADOW-CONFIG-HERE -->
|
* man/login.defs.d/CONSOLE_GROUPS.xml,
man/login.defs.d/CONSOLE.xml, man/login.defs.d/DEFAULT_HOME.xml,
man/login.defs.d/ENV_HZ.xml, man/login.defs.d/ENVIRON_FILE.xml,
man/login.defs.d/ENV_PATH.xml, man/login.defs.d/ENV_SUPATH.xml,
man/login.defs.d/ENV_TZ.xml, man/login.defs.d/ERASECHAR.xml,
man/login.defs.d/FAIL_DELAY.xml,
man/login.defs.d/FAILLOG_ENAB.xml,
man/login.defs.d/FAKE_SHELL.xml, man/login.defs.d/FTMP_FILE.xml,
man/login.defs.d/HUSHLOGIN_FILE.xml,
man/login.defs.d/ISSUE_FILE.xml, man/login.defs.d/KILLCHAR.xml,
man/login.defs.d/LASTLOG_ENAB.xml, man/login.defs.d/LOGIN_RETRIES.xml,
man/login.defs.d/LOGIN_TIMEOUT.xml, man/login.defs.d/LOG_OK_LOGINS.xml,
man/login.defs.d/LOG_UNKFAIL_ENAB.xml,
man/login.defs.d/MAIL_CHECK_ENAB.xml, man/login.defs.d/MOTD_FILE.xml,
man/login.defs.d/NOLOGINS_FILE.xml,
man/login.defs.d/OBSCURE_CHECKS_ENAB.xml,
man/login.defs.d/PASS_ALWAYS_WARN.xml,
man/login.defs.d/PASS_CHANGE_TRIES.xml,
man/login.defs.d/PASS_MAX_LEN.xml,
man/login.defs.d/PORTTIME_CHECKS_ENAB.xml,
man/login.defs.d/QUOTAS_ENAB.xml, man/login.defs.d/SULOG_FILE.xml,
man/login.defs.d/SU_NAME.xml, man/login.defs.d/SU_WHEEL_ONLY.xml,
man/login.defs.d/SYSLOG_SG_ENAB.xml,
man/login.defs.d/SYSLOG_SU_ENAB.xml,
man/login.defs.d/TTYGROUP.xml, man/login.defs.d/TTYTYPE_FILE.xml,
man/login.defs.d/ULIMIT.xml, man/login.defs.d/USERGROUPS_ENAB.xml:
New documentation of login.defs variables.
* man/login.defs.d/MAIL_DIR.xml: Updated. It now contains the
MAIL_FILE documentation.
* man/login.defs.d/LOGIN_STRING.xml: Updated. Mentions %s.
* man/pwconv.8.xml, man/groupmems.8.xml, man/groupdel.8.xml,
man/useradd.8.xml, man/pwck.8.xml, man/groupadd.8.xml,
man/sulogin.8.xml, man/newgrp.1.xml, man/usermod.8.xml,
man/su.1.xml, man/vipw.8.xml, man/passwd.1.xml,
man/groupmod.8.xml, man/login.1.xml, man/userdel.8.xml,
man/grpck.8.xml: Added CONFIGURATION section.
* man/generate_mans.mak: The generations of manpages depends on
the variables from the Makefiles. Add the dependency on Makefile.
* man/login.defs.5.xml: New login.defs variable documented.
* man/Makefile.am: Added XML variable documentation to the
distributed files.
2007-12-09 04:54:40 +05:30
|
|
|
]>
|
2007-10-07 17:16:16 +05:30
|
|
|
<refentry id='usermod.8'>
|
2007-11-11 05:16:11 +05:30
|
|
|
<!-- $Id$ -->
|
2012-05-25 17:15:21 +05:30
|
|
|
<refentryinfo>
|
|
|
|
<author>
|
|
|
|
<firstname>Julianne Frances</firstname>
|
|
|
|
<surname>Haugh</surname>
|
|
|
|
<contrib>Creation, 1991</contrib>
|
|
|
|
</author>
|
|
|
|
<author>
|
|
|
|
<firstname>Thomas</firstname>
|
|
|
|
<surname>Kłoczko</surname>
|
|
|
|
<email>kloczek@pld.org.pl</email>
|
|
|
|
<contrib>shadow-utils maintainer, 2000 - 2007</contrib>
|
|
|
|
</author>
|
|
|
|
<author>
|
|
|
|
<firstname>Nicolas</firstname>
|
|
|
|
<surname>François</surname>
|
|
|
|
<email>nicolas.francois@centraliens.net</email>
|
|
|
|
<contrib>shadow-utils maintainer, 2007 - now</contrib>
|
|
|
|
</author>
|
|
|
|
</refentryinfo>
|
2007-10-07 17:16:16 +05:30
|
|
|
<refmeta>
|
|
|
|
<refentrytitle>usermod</refentrytitle>
|
|
|
|
<manvolnum>8</manvolnum>
|
2007-10-07 17:17:11 +05:30
|
|
|
<refmiscinfo class="sectdesc">System Management Commands</refmiscinfo>
|
2011-07-09 01:19:09 +05:30
|
|
|
<refmiscinfo class="source">shadow-utils</refmiscinfo>
|
|
|
|
<refmiscinfo class="version">&SHADOW_UTILS_VERSION;</refmiscinfo>
|
2007-10-07 17:16:16 +05:30
|
|
|
</refmeta>
|
|
|
|
<refnamediv id='name'>
|
|
|
|
<refname>usermod</refname>
|
2007-10-07 17:17:33 +05:30
|
|
|
<refpurpose>modify a user account</refpurpose>
|
2007-10-07 17:16:16 +05:30
|
|
|
</refnamediv>
|
|
|
|
|
|
|
|
<refsynopsisdiv id='synopsis'>
|
|
|
|
<cmdsynopsis>
|
2007-10-07 17:17:01 +05:30
|
|
|
<command>usermod</command>
|
2007-10-07 17:16:16 +05:30
|
|
|
<arg choice='opt'>
|
2007-10-07 17:17:11 +05:30
|
|
|
<replaceable>options</replaceable>
|
2007-10-07 17:16:16 +05:30
|
|
|
</arg>
|
2007-10-07 17:17:11 +05:30
|
|
|
<arg choice='plain'><replaceable>LOGIN</replaceable></arg>
|
2007-10-07 17:16:16 +05:30
|
|
|
</cmdsynopsis>
|
|
|
|
</refsynopsisdiv>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
2007-10-07 17:16:16 +05:30
|
|
|
<refsect1 id='description'>
|
|
|
|
<title>DESCRIPTION</title>
|
|
|
|
<para>
|
|
|
|
The <command>usermod</command> command modifies the system account
|
2022-03-07 05:42:13 +05:30
|
|
|
files.
|
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='options'>
|
|
|
|
<title>OPTIONS</title>
|
|
|
|
<para>
|
|
|
|
The options which apply to the <command>usermod</command> command
|
|
|
|
are:
|
|
|
|
</para>
|
2009-04-06 02:53:55 +05:30
|
|
|
<variablelist>
|
2007-10-07 17:17:33 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term>
|
|
|
|
<option>-a</option>, <option>--append</option>
|
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2009-05-20 03:58:34 +05:30
|
|
|
Add the user to the supplementary group(s). Use only with the
|
2007-10-07 17:17:57 +05:30
|
|
|
<option>-G</option> option.
|
2007-10-07 17:17:33 +05:30
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2019-08-24 02:12:37 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term>
|
2022-04-27 20:29:03 +05:30
|
|
|
<option>-b</option>, <option>--badname</option>
|
2019-08-24 02:12:37 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
Allow names that do not conform to standards.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2007-10-07 17:16:16 +05:30
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-c</option>, <option>--comment</option> <replaceable>COMMENT</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
update the comment field of the user in <filename>/etc/passwd
|
|
|
|
</filename>, which is normally modified using the <citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>chfn</refentrytitle><manvolnum>1</manvolnum>
|
|
|
|
</citerefentry> utility.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-d</option>, <option>--home</option> <replaceable>HOME_DIR</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2009-04-06 02:53:55 +05:30
|
|
|
The user's new login directory.
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
If the <option>-m</option>
|
2009-05-20 03:58:34 +05:30
|
|
|
option is given, the contents of the current home directory will
|
2007-10-07 17:17:01 +05:30
|
|
|
be moved to the new home directory, which is created if it does
|
2021-02-02 15:57:17 +05:30
|
|
|
not already exist. If the current home directory does not exist
|
|
|
|
the new home directory will not be created.
|
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>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-e</option>, <option>--expiredate</option> <replaceable>EXPIRE_DATE</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
The date on which the user account will be disabled. The
|
|
|
|
date is specified in the format
|
2022-03-08 05:21:18 +05:30
|
|
|
<emphasis remap="I">YYYY-MM-DD</emphasis>. Integers as input are
|
2022-03-07 05:42:13 +05:30
|
|
|
interpreted as days after 1970-01-01.
|
2007-10-07 17:17:01 +05:30
|
|
|
</para>
|
2011-07-14 18:59:43 +05:30
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
An input of -1 or an empty string will blank the account
|
|
|
|
expiration field in the shadow password file. The account
|
|
|
|
will remain available with no date limit.
|
2011-07-14 18:59:43 +05:30
|
|
|
</para>
|
2011-07-14 18:59:37 +05:30
|
|
|
<para>
|
|
|
|
This option requires a <filename>/etc/shadow</filename> file.
|
|
|
|
A <filename>/etc/shadow</filename> entry will be created if
|
|
|
|
there were none.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-f</option>, <option>--inactive</option> <replaceable>INACTIVE</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
defines the number of days after the password exceeded its maximum
|
|
|
|
age during which the user may still login by immediately replacing
|
|
|
|
the password. This grace period before the account becomes inactive
|
|
|
|
is stored in the shadow password file. An input of 0 will disable an
|
|
|
|
expired password with no delay. An input of -1 will blank the
|
|
|
|
respective field in the shadow password file. See <citerefentry>
|
|
|
|
<refentrytitle>shadow</refentrytitle><manvolnum>5</manvolnum>
|
|
|
|
</citerefentry> for more information.
|
2007-10-07 17:17:01 +05:30
|
|
|
</para>
|
2011-07-14 18:59:37 +05:30
|
|
|
<para>
|
|
|
|
This option requires a <filename>/etc/shadow</filename> file.
|
|
|
|
A <filename>/etc/shadow</filename> entry will be created if
|
|
|
|
there were none.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-g</option>, <option>--gid</option> <replaceable>GROUP</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
The name or numerical ID of the user's new primary group.
|
2009-04-15 03:49:11 +05:30
|
|
|
The group must exist.
|
2007-10-07 17:17:01 +05:30
|
|
|
</para>
|
2010-04-05 02:53:02 +05:30
|
|
|
<para>
|
|
|
|
Any file from the user's home directory owned by the previous
|
|
|
|
primary group of the user will be owned by this new group.
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
The group ownership of files outside of the user's home directory
|
|
|
|
must be fixed manually.
|
|
|
|
</para>
|
2021-02-02 15:57:17 +05:30
|
|
|
<para>
|
|
|
|
The change of the group ownership of files inside of the user's
|
|
|
|
home directory is also not done if the home dir owner uid is
|
|
|
|
different from the current or new user id. This is a safety measure
|
|
|
|
for special home directories such as <filename>/</filename>.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-G</option>, <option>--groups</option> <replaceable>GROUP1</replaceable>[<emphasis remap='I'>,GROUP2,...</emphasis>[<emphasis remap='I'>,GROUPN</emphasis>]]]
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
A list of supplementary groups which the user is also a member
|
|
|
|
of. Each group is separated from the next by a comma, with no
|
2022-03-07 05:42:13 +05:30
|
|
|
intervening whitespace. The groups must exist.
|
2009-04-06 02:53:55 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
If the user is currently a member of a group which is
|
2007-10-07 17:17:01 +05:30
|
|
|
not listed, the user will be removed from the group. This
|
2007-10-07 20:06:51 +05:30
|
|
|
behaviour can be changed via the <option>-a</option> option, which
|
|
|
|
appends the user to the current supplementary group list.
|
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>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-l</option>, <option>--login</option> <replaceable>NEW_LOGIN</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2009-03-14 04:44:18 +05:30
|
|
|
The name of the user will be changed from
|
|
|
|
<replaceable>LOGIN</replaceable> to
|
|
|
|
<replaceable>NEW_LOGIN</replaceable>. Nothing else is changed. In
|
2011-07-14 18:59:43 +05:30
|
|
|
particular, the user's home directory or mail spool should
|
|
|
|
probably be renamed manually to reflect the new login name.
|
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>
|
2007-10-07 17:17:11 +05:30
|
|
|
<option>-L</option>, <option>--lock</option>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
Lock a user's password. This puts a '!' in front of the
|
|
|
|
encrypted password, effectively disabling the password. You
|
|
|
|
can't use this option with <option>-p</option> or
|
|
|
|
<option>-U</option>.
|
|
|
|
</para>
|
2007-11-18 03:37:47 +05:30
|
|
|
<para>
|
|
|
|
Note: if you wish to lock the account (not only access with a
|
|
|
|
password), you should also set the
|
|
|
|
<replaceable>EXPIRE_DATE</replaceable> to
|
|
|
|
<replaceable>1</replaceable>.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
2009-05-18 23:58:06 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term>
|
|
|
|
<option>-m</option>, <option>--move-home</option>
|
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
moves the content of the user's home directory to the new
|
2021-02-02 15:57:17 +05:30
|
|
|
location. If the current home directory does not exist
|
|
|
|
the new home directory will not be created.
|
2009-05-18 23:58:06 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
This option is only valid in combination with the
|
|
|
|
<option>-d</option> (or <option>--home</option>) option.
|
|
|
|
</para>
|
2010-03-31 02:31:27 +05:30
|
|
|
<para>
|
|
|
|
<command>usermod</command> will try to adapt the ownership of the
|
|
|
|
files and to copy the modes, ACL and extended attributes, but
|
|
|
|
manual changes might be needed afterwards.
|
|
|
|
</para>
|
2009-05-18 23:58:06 +05:30
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2007-10-07 17:16:16 +05:30
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2007-10-07 17:17:11 +05:30
|
|
|
<option>-o</option>, <option>--non-unique</option>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
allows to change the user ID to a non-unique value.
|
|
|
|
</para>
|
2022-03-07 05:42:13 +05:30
|
|
|
<para>
|
|
|
|
This option is only valid in combination with the
|
|
|
|
<option>-u</option> option. As a user identity
|
|
|
|
serves as
|
|
|
|
key to map between users on one hand and permissions, file
|
|
|
|
ownerships and other aspects that determine the system's
|
|
|
|
behavior on the other hand, more than one login name
|
|
|
|
will access the account of the given UID.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-p</option>, <option>--password</option> <replaceable>PASSWORD</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
defines a new password for the user. PASSWORD is expected to
|
|
|
|
be encrypted, as returned by <citerefentry><refentrytitle>crypt
|
|
|
|
</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
|
2007-10-07 17:17:01 +05:30
|
|
|
</para>
|
2009-04-28 01:59:43 +05:30
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
<emphasis role="bold">Note:</emphasis> Avoid this option on the
|
|
|
|
command line because the password (or encrypted password) will
|
2009-04-28 01:59:43 +05:30
|
|
|
be visible by users listing the processes.
|
|
|
|
</para>
|
2009-05-20 02:59:26 +05:30
|
|
|
<para condition="pam">
|
|
|
|
The password will be written in the local
|
|
|
|
<filename>/etc/passwd</filename> or
|
|
|
|
<filename>/etc/shadow</filename> file. This might differ from the
|
|
|
|
password database configured in your PAM configuration.
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
You should make sure the password respects the system's
|
|
|
|
password policy.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
2021-09-23 08:59:09 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term>
|
|
|
|
<option>-r</option>, <option>--remove</option>
|
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
Remove the user from named supplementary group(s). Use only with the
|
|
|
|
<option>-G</option> option.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2011-11-07 00:07:39 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-R</option>, <option>--root</option> <replaceable>CHROOT_DIR</replaceable>
|
2011-11-07 00:07:39 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
Apply changes in the <replaceable>CHROOT_DIR</replaceable>
|
|
|
|
directory and use the configuration files from the
|
|
|
|
<replaceable>CHROOT_DIR</replaceable> directory.
|
2022-07-27 20:36:36 +05:30
|
|
|
Only absolute paths are supported.
|
2011-11-07 00:07:39 +05:30
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2016-05-15 19:19:39 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term>
|
|
|
|
<option>-P</option>, <option>--prefix</option> <replaceable>PREFIX_DIR</replaceable>
|
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
Apply changes within the directory tree starting with
|
|
|
|
<replaceable>PREFIX_DIR</replaceable> and use as well the
|
|
|
|
configuration files located there. This option does not
|
|
|
|
chroot and is intended for preparing a cross-compilation
|
|
|
|
target. Some limitations: NIS and LDAP users/groups are
|
|
|
|
not verified. PAM authentication is using the host
|
|
|
|
files. No SELINUX support.
|
2016-05-15 19:19:39 +05:30
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2007-10-07 17:16:16 +05:30
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-s</option>, <option>--shell</option> <replaceable>SHELL</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
2007-10-07 17:17:11 +05:30
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
changes the user's login shell. An empty string for SHELL blanks the
|
|
|
|
field in <filename>/etc/passwd</filename> and logs the user into the
|
|
|
|
system's default shell.
|
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>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-u</option>, <option>--uid</option> <replaceable>UID</replaceable>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
The new value of the user's ID.
|
2009-04-06 02:53:55 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
This value must be unique,
|
2007-10-07 17:17:01 +05:30
|
|
|
unless the <option>-o</option> option is used. The value must be
|
2011-11-19 20:03:53 +05:30
|
|
|
non-negative.
|
2009-04-06 02:53:55 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
2009-05-20 03:27:04 +05:30
|
|
|
The user's mailbox, and any files which the user owns and which are
|
|
|
|
located in the user's home
|
|
|
|
directory will have the file user ID changed automatically.
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
The ownership of files outside of the user's home directory
|
|
|
|
must be fixed manually.
|
2007-10-07 17:17:01 +05:30
|
|
|
</para>
|
2021-02-02 15:57:17 +05:30
|
|
|
<para>
|
|
|
|
The change of the user ownership of files inside of the user's
|
|
|
|
home directory is also not done if the home dir owner uid is
|
|
|
|
different from the current or new user id. This is a safety measure
|
|
|
|
for special home directories such as <filename>/</filename>.
|
|
|
|
</para>
|
2011-11-19 20:03:53 +05:30
|
|
|
<para>
|
|
|
|
No checks will be performed with regard to the
|
|
|
|
<option>UID_MIN</option>, <option>UID_MAX</option>,
|
|
|
|
<option>SYS_UID_MIN</option>, or <option>SYS_UID_MAX</option>
|
|
|
|
from <filename>/etc/login.defs</filename>.
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term>
|
2007-10-07 17:17:11 +05:30
|
|
|
<option>-U</option>, <option>--unlock</option>
|
2007-10-07 17:17:01 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
Unlock a user's password. This removes the '!' in front of the
|
|
|
|
encrypted password. You can't use this option with
|
|
|
|
<option>-p</option> or <option>-L</option>.
|
|
|
|
</para>
|
2007-11-18 03:37:47 +05:30
|
|
|
<para>
|
|
|
|
Note: if you wish to unlock the account (not only access with a
|
|
|
|
password), you should also set the
|
|
|
|
<replaceable>EXPIRE_DATE</replaceable> (for example to
|
|
|
|
<replaceable>99999</replaceable>, or to the
|
2009-05-21 17:32:12 +05:30
|
|
|
<option>EXPIRE</option> value from
|
2007-11-18 03:37:47 +05:30
|
|
|
<filename>/etc/default/useradd</filename>).
|
|
|
|
</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
Allow disabling of subordinate IDs.
* configure.in: Add configure options --enable-subordinate-ids /
--disable-subordinate-ids. Enabled by default.
* lib/prototypes.h: Include <config.h> before using its macros.
* lib/commonio.h, lib/commonio.c: Define commonio_append only when
ENABLE_SUBIDS is defined.
* lib/prototypes.h, libmisc/find_new_sub_gids.c,
libmisc/find_new_sub_uids.c: Likewise.
* lib/subordinateio.h, lib/subordinateio.c: Likewise.
* libmisc/user_busy.c: Only check if subordinate IDs are in use if
ENABLE_SUBIDS is defined.
* src/Makefile.am: Create newgidmap and newuidmap only if
ENABLE_SUBIDS is defined.
* src/newusers.c: Check for ENABLE_SUBIDS to enable support for
subordinate IDs.
* src/useradd.c: Likewise.
* src/userdel.c: Likewise.
* src/usermod.c: Likewise.
* man/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 only if ENABLE_SUBIDS is defined.
* man/fr/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 (not translated yet).
* man/generate_mans.mak: Add xsltproc conditionals
subids/no_subids.
* man/login.defs.d/SUB_GID_COUNT.xml: Add dependency on subids
condition.
* man/login.defs.d/SUB_UID_COUNT.xml: Likewise.
* man/usermod.8.xml: Document options for subordinate IDs and
reference subgid(5) / subuid(5) depending on the subids condition.
2013-08-11 18:24:22 +05:30
|
|
|
<varlistentry condition="subids">
|
2013-01-22 14:48:24 +05:30
|
|
|
<term>
|
2016-11-10 02:53:18 +05:30
|
|
|
<option>-v</option>, <option>--add-subuids</option> <replaceable>FIRST</replaceable>-<replaceable>LAST</replaceable>
|
2013-01-22 14:48:24 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2013-08-07 05:02:56 +05:30
|
|
|
Add a range of subordinate uids to the user's account.
|
2013-01-22 14:48:24 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
This option may be specified multiple times to add multiple ranges to a user's account.
|
2013-01-22 14:48:24 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
No checks will be performed with regard to
|
|
|
|
<option>SUB_UID_MIN</option>, <option>SUB_UID_MAX</option>, or
|
|
|
|
<option>SUB_UID_COUNT</option> from /etc/login.defs.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
Allow disabling of subordinate IDs.
* configure.in: Add configure options --enable-subordinate-ids /
--disable-subordinate-ids. Enabled by default.
* lib/prototypes.h: Include <config.h> before using its macros.
* lib/commonio.h, lib/commonio.c: Define commonio_append only when
ENABLE_SUBIDS is defined.
* lib/prototypes.h, libmisc/find_new_sub_gids.c,
libmisc/find_new_sub_uids.c: Likewise.
* lib/subordinateio.h, lib/subordinateio.c: Likewise.
* libmisc/user_busy.c: Only check if subordinate IDs are in use if
ENABLE_SUBIDS is defined.
* src/Makefile.am: Create newgidmap and newuidmap only if
ENABLE_SUBIDS is defined.
* src/newusers.c: Check for ENABLE_SUBIDS to enable support for
subordinate IDs.
* src/useradd.c: Likewise.
* src/userdel.c: Likewise.
* src/usermod.c: Likewise.
* man/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 only if ENABLE_SUBIDS is defined.
* man/fr/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 (not translated yet).
* man/generate_mans.mak: Add xsltproc conditionals
subids/no_subids.
* man/login.defs.d/SUB_GID_COUNT.xml: Add dependency on subids
condition.
* man/login.defs.d/SUB_UID_COUNT.xml: Likewise.
* man/usermod.8.xml: Document options for subordinate IDs and
reference subgid(5) / subuid(5) depending on the subids condition.
2013-08-11 18:24:22 +05:30
|
|
|
<varlistentry condition="subids">
|
2013-01-22 14:48:24 +05:30
|
|
|
<term>
|
2016-11-10 02:53:18 +05:30
|
|
|
<option>-V</option>, <option>--del-subuids</option> <replaceable>FIRST</replaceable>-<replaceable>LAST</replaceable>
|
2013-01-22 14:48:24 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2013-08-07 05:02:56 +05:30
|
|
|
Remove a range of subordinate uids from the user's account.
|
2013-01-22 14:48:24 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
This option may be specified multiple times to remove multiple ranges to a user's account.
|
2016-11-10 02:53:18 +05:30
|
|
|
When both <option>--del-subuids</option> and <option>--add-subuids</option> are specified,
|
2013-08-07 05:02:56 +05:30
|
|
|
the removal of all subordinate uid ranges happens before any subordinate uid range is added.
|
2013-01-22 14:48:24 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
No checks will be performed with regard to
|
|
|
|
<option>SUB_UID_MIN</option>, <option>SUB_UID_MAX</option>, or
|
|
|
|
<option>SUB_UID_COUNT</option> from /etc/login.defs.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
Allow disabling of subordinate IDs.
* configure.in: Add configure options --enable-subordinate-ids /
--disable-subordinate-ids. Enabled by default.
* lib/prototypes.h: Include <config.h> before using its macros.
* lib/commonio.h, lib/commonio.c: Define commonio_append only when
ENABLE_SUBIDS is defined.
* lib/prototypes.h, libmisc/find_new_sub_gids.c,
libmisc/find_new_sub_uids.c: Likewise.
* lib/subordinateio.h, lib/subordinateio.c: Likewise.
* libmisc/user_busy.c: Only check if subordinate IDs are in use if
ENABLE_SUBIDS is defined.
* src/Makefile.am: Create newgidmap and newuidmap only if
ENABLE_SUBIDS is defined.
* src/newusers.c: Check for ENABLE_SUBIDS to enable support for
subordinate IDs.
* src/useradd.c: Likewise.
* src/userdel.c: Likewise.
* src/usermod.c: Likewise.
* man/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 only if ENABLE_SUBIDS is defined.
* man/fr/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 (not translated yet).
* man/generate_mans.mak: Add xsltproc conditionals
subids/no_subids.
* man/login.defs.d/SUB_GID_COUNT.xml: Add dependency on subids
condition.
* man/login.defs.d/SUB_UID_COUNT.xml: Likewise.
* man/usermod.8.xml: Document options for subordinate IDs and
reference subgid(5) / subuid(5) depending on the subids condition.
2013-08-11 18:24:22 +05:30
|
|
|
<varlistentry condition="subids">
|
2013-01-22 14:48:24 +05:30
|
|
|
<term>
|
2016-11-10 02:53:18 +05:30
|
|
|
<option>-w</option>, <option>--add-subgids</option> <replaceable>FIRST</replaceable>-<replaceable>LAST</replaceable>
|
2013-01-22 14:48:24 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2013-08-07 05:02:56 +05:30
|
|
|
Add a range of subordinate gids to the user's account.
|
2013-01-22 14:48:24 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
This option may be specified multiple times to add multiple ranges to a user's account.
|
2013-01-22 14:48:24 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
No checks will be performed with regard to
|
|
|
|
<option>SUB_GID_MIN</option>, <option>SUB_GID_MAX</option>, or
|
|
|
|
<option>SUB_GID_COUNT</option> from /etc/login.defs.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
Allow disabling of subordinate IDs.
* configure.in: Add configure options --enable-subordinate-ids /
--disable-subordinate-ids. Enabled by default.
* lib/prototypes.h: Include <config.h> before using its macros.
* lib/commonio.h, lib/commonio.c: Define commonio_append only when
ENABLE_SUBIDS is defined.
* lib/prototypes.h, libmisc/find_new_sub_gids.c,
libmisc/find_new_sub_uids.c: Likewise.
* lib/subordinateio.h, lib/subordinateio.c: Likewise.
* libmisc/user_busy.c: Only check if subordinate IDs are in use if
ENABLE_SUBIDS is defined.
* src/Makefile.am: Create newgidmap and newuidmap only if
ENABLE_SUBIDS is defined.
* src/newusers.c: Check for ENABLE_SUBIDS to enable support for
subordinate IDs.
* src/useradd.c: Likewise.
* src/userdel.c: Likewise.
* src/usermod.c: Likewise.
* man/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 only if ENABLE_SUBIDS is defined.
* man/fr/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 (not translated yet).
* man/generate_mans.mak: Add xsltproc conditionals
subids/no_subids.
* man/login.defs.d/SUB_GID_COUNT.xml: Add dependency on subids
condition.
* man/login.defs.d/SUB_UID_COUNT.xml: Likewise.
* man/usermod.8.xml: Document options for subordinate IDs and
reference subgid(5) / subuid(5) depending on the subids condition.
2013-08-11 18:24:22 +05:30
|
|
|
<varlistentry condition="subids">
|
2013-01-22 14:48:24 +05:30
|
|
|
<term>
|
2016-11-10 02:53:18 +05:30
|
|
|
<option>-W</option>, <option>--del-subgids</option> <replaceable>FIRST</replaceable>-<replaceable>LAST</replaceable>
|
2013-01-22 14:48:24 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2013-08-07 05:02:56 +05:30
|
|
|
Remove a range of subordinate gids from the user's account.
|
2013-01-22 14:48:24 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
This option may be specified multiple times to remove multiple ranges to a user's account.
|
2016-11-10 02:53:18 +05:30
|
|
|
When both <option>--del-subgids</option> and <option>--add-subgids</option> are specified,
|
2013-08-07 05:02:56 +05:30
|
|
|
the removal of all subordinate gid ranges happens before any subordinate gid range is added.
|
2013-01-22 14:48:24 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
No checks will be performed with regard to
|
|
|
|
<option>SUB_GID_MIN</option>, <option>SUB_GID_MAX</option>, or
|
|
|
|
<option>SUB_GID_COUNT</option> from /etc/login.defs.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2011-11-18 03:02:26 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term>
|
2013-08-23 03:24:34 +05:30
|
|
|
<option>-Z</option>, <option>--selinux-user</option> <replaceable>SEUSER</replaceable>
|
2011-11-18 03:02:26 +05:30
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
2022-03-07 05:42:13 +05:30
|
|
|
defines the SELinux user to be mapped with
|
|
|
|
<replaceable>LOGIN</replaceable>. An empty string ("")
|
|
|
|
will remove the respective entry (if any). Note that the
|
|
|
|
shadow system doesn't store the selinux-user, it uses
|
|
|
|
semanage(8) for that.
|
2011-11-18 03:02:26 +05:30
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2023-04-01 18:04:56 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term>
|
|
|
|
<option>--selinux-range</option> <replaceable>SERANGE</replaceable>
|
|
|
|
</term>
|
|
|
|
<listitem>
|
|
|
|
<para>
|
|
|
|
defines the SELinux MLS range for the new account.
|
|
|
|
Note that the shadow system doesn't store the selinux-range,
|
|
|
|
it uses <citerefentry><refentrytitle>semanage</refentrytitle>
|
|
|
|
<manvolnum>8</manvolnum></citerefentry> for that.
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
This option is only valid if the <option>-Z</option> (or
|
|
|
|
<option>--selinux-user</option>) option is specified.
|
|
|
|
</para>
|
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2007-10-07 17:16:16 +05:30
|
|
|
</variablelist>
|
|
|
|
</refsect1>
|
|
|
|
|
|
|
|
<refsect1 id='caveats'>
|
|
|
|
<title>CAVEATS</title>
|
2007-10-07 17:17:01 +05:30
|
|
|
<para>
|
2009-05-19 00:48:29 +05:30
|
|
|
You must make certain that the named user is
|
2007-10-07 17:16:16 +05:30
|
|
|
not executing any processes when this command is being executed if the
|
2009-05-19 00:48:29 +05:30
|
|
|
user's numerical user ID, the user's name, or the user's home
|
|
|
|
directory is being changed. <command>usermod</command> checks this
|
2022-03-07 05:42:13 +05:30
|
|
|
on Linux. On other operating systems it only uses utmp to check if
|
|
|
|
the user is logged in.
|
2009-05-19 00:48:29 +05:30
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
You must change the owner of any <command>crontab</command> files or
|
|
|
|
<command>at</command> jobs manually.
|
|
|
|
</para>
|
|
|
|
<para>
|
|
|
|
You must make any changes involving NIS on the NIS server.
|
2007-10-07 17:16:16 +05:30
|
|
|
</para>
|
|
|
|
</refsect1>
|
2007-10-07 17:17:01 +05:30
|
|
|
|
* man/login.defs.d/CONSOLE_GROUPS.xml,
man/login.defs.d/CONSOLE.xml, man/login.defs.d/DEFAULT_HOME.xml,
man/login.defs.d/ENV_HZ.xml, man/login.defs.d/ENVIRON_FILE.xml,
man/login.defs.d/ENV_PATH.xml, man/login.defs.d/ENV_SUPATH.xml,
man/login.defs.d/ENV_TZ.xml, man/login.defs.d/ERASECHAR.xml,
man/login.defs.d/FAIL_DELAY.xml,
man/login.defs.d/FAILLOG_ENAB.xml,
man/login.defs.d/FAKE_SHELL.xml, man/login.defs.d/FTMP_FILE.xml,
man/login.defs.d/HUSHLOGIN_FILE.xml,
man/login.defs.d/ISSUE_FILE.xml, man/login.defs.d/KILLCHAR.xml,
man/login.defs.d/LASTLOG_ENAB.xml, man/login.defs.d/LOGIN_RETRIES.xml,
man/login.defs.d/LOGIN_TIMEOUT.xml, man/login.defs.d/LOG_OK_LOGINS.xml,
man/login.defs.d/LOG_UNKFAIL_ENAB.xml,
man/login.defs.d/MAIL_CHECK_ENAB.xml, man/login.defs.d/MOTD_FILE.xml,
man/login.defs.d/NOLOGINS_FILE.xml,
man/login.defs.d/OBSCURE_CHECKS_ENAB.xml,
man/login.defs.d/PASS_ALWAYS_WARN.xml,
man/login.defs.d/PASS_CHANGE_TRIES.xml,
man/login.defs.d/PASS_MAX_LEN.xml,
man/login.defs.d/PORTTIME_CHECKS_ENAB.xml,
man/login.defs.d/QUOTAS_ENAB.xml, man/login.defs.d/SULOG_FILE.xml,
man/login.defs.d/SU_NAME.xml, man/login.defs.d/SU_WHEEL_ONLY.xml,
man/login.defs.d/SYSLOG_SG_ENAB.xml,
man/login.defs.d/SYSLOG_SU_ENAB.xml,
man/login.defs.d/TTYGROUP.xml, man/login.defs.d/TTYTYPE_FILE.xml,
man/login.defs.d/ULIMIT.xml, man/login.defs.d/USERGROUPS_ENAB.xml:
New documentation of login.defs variables.
* man/login.defs.d/MAIL_DIR.xml: Updated. It now contains the
MAIL_FILE documentation.
* man/login.defs.d/LOGIN_STRING.xml: Updated. Mentions %s.
* man/pwconv.8.xml, man/groupmems.8.xml, man/groupdel.8.xml,
man/useradd.8.xml, man/pwck.8.xml, man/groupadd.8.xml,
man/sulogin.8.xml, man/newgrp.1.xml, man/usermod.8.xml,
man/su.1.xml, man/vipw.8.xml, man/passwd.1.xml,
man/groupmod.8.xml, man/login.1.xml, man/userdel.8.xml,
man/grpck.8.xml: Added CONFIGURATION section.
* man/generate_mans.mak: The generations of manpages depends on
the variables from the Makefiles. Add the dependency on Makefile.
* man/login.defs.5.xml: New login.defs variable documented.
* man/Makefile.am: Added XML variable documentation to the
distributed files.
2007-12-09 04:54:40 +05:30
|
|
|
<refsect1 id='configuration'>
|
|
|
|
<title>CONFIGURATION</title>
|
|
|
|
<para>
|
|
|
|
The following configuration variables in
|
|
|
|
<filename>/etc/login.defs</filename> change the behavior of this
|
|
|
|
tool:
|
|
|
|
</para>
|
|
|
|
<variablelist>
|
2018-11-28 19:27:16 +05:30
|
|
|
&LASTLOG_UID_MAX;
|
* man/login.defs.d/CONSOLE_GROUPS.xml,
man/login.defs.d/CONSOLE.xml, man/login.defs.d/DEFAULT_HOME.xml,
man/login.defs.d/ENV_HZ.xml, man/login.defs.d/ENVIRON_FILE.xml,
man/login.defs.d/ENV_PATH.xml, man/login.defs.d/ENV_SUPATH.xml,
man/login.defs.d/ENV_TZ.xml, man/login.defs.d/ERASECHAR.xml,
man/login.defs.d/FAIL_DELAY.xml,
man/login.defs.d/FAILLOG_ENAB.xml,
man/login.defs.d/FAKE_SHELL.xml, man/login.defs.d/FTMP_FILE.xml,
man/login.defs.d/HUSHLOGIN_FILE.xml,
man/login.defs.d/ISSUE_FILE.xml, man/login.defs.d/KILLCHAR.xml,
man/login.defs.d/LASTLOG_ENAB.xml, man/login.defs.d/LOGIN_RETRIES.xml,
man/login.defs.d/LOGIN_TIMEOUT.xml, man/login.defs.d/LOG_OK_LOGINS.xml,
man/login.defs.d/LOG_UNKFAIL_ENAB.xml,
man/login.defs.d/MAIL_CHECK_ENAB.xml, man/login.defs.d/MOTD_FILE.xml,
man/login.defs.d/NOLOGINS_FILE.xml,
man/login.defs.d/OBSCURE_CHECKS_ENAB.xml,
man/login.defs.d/PASS_ALWAYS_WARN.xml,
man/login.defs.d/PASS_CHANGE_TRIES.xml,
man/login.defs.d/PASS_MAX_LEN.xml,
man/login.defs.d/PORTTIME_CHECKS_ENAB.xml,
man/login.defs.d/QUOTAS_ENAB.xml, man/login.defs.d/SULOG_FILE.xml,
man/login.defs.d/SU_NAME.xml, man/login.defs.d/SU_WHEEL_ONLY.xml,
man/login.defs.d/SYSLOG_SG_ENAB.xml,
man/login.defs.d/SYSLOG_SU_ENAB.xml,
man/login.defs.d/TTYGROUP.xml, man/login.defs.d/TTYTYPE_FILE.xml,
man/login.defs.d/ULIMIT.xml, man/login.defs.d/USERGROUPS_ENAB.xml:
New documentation of login.defs variables.
* man/login.defs.d/MAIL_DIR.xml: Updated. It now contains the
MAIL_FILE documentation.
* man/login.defs.d/LOGIN_STRING.xml: Updated. Mentions %s.
* man/pwconv.8.xml, man/groupmems.8.xml, man/groupdel.8.xml,
man/useradd.8.xml, man/pwck.8.xml, man/groupadd.8.xml,
man/sulogin.8.xml, man/newgrp.1.xml, man/usermod.8.xml,
man/su.1.xml, man/vipw.8.xml, man/passwd.1.xml,
man/groupmod.8.xml, man/login.1.xml, man/userdel.8.xml,
man/grpck.8.xml: Added CONFIGURATION section.
* man/generate_mans.mak: The generations of manpages depends on
the variables from the Makefiles. Add the dependency on Makefile.
* man/login.defs.5.xml: New login.defs variable documented.
* man/Makefile.am: Added XML variable documentation to the
distributed files.
2007-12-09 04:54:40 +05:30
|
|
|
&MAIL_DIR; <!-- documents also MAIL_FILE -->
|
|
|
|
&MAX_MEMBERS_PER_GROUP;
|
2013-08-11 19:35:26 +05:30
|
|
|
&SUB_GID_COUNT; <!-- documents also SUB_GID_MAX and SUB_GID_MIN -->
|
|
|
|
&SUB_UID_COUNT; <!-- documents also SUB_UID_MAX and SUB_UID_MIN -->
|
* man/chage.1.xml, man/login.defs.5.xml, man/pwck.8.xml,
man/pwconv.8.xml, man/useradd.8.xml, man/userdel.8.xml,
man/usermod.8.xml, man/vipw.8.xml: Document the usage of the
TCB_AUTH_GROUP, TCB_SYMLINKS, and USE_TCB configuration
parameters.
* man/pwconv.8.xml, man/pwck.8.xml: Document the behavior when
USE_TCB is enabled.
2010-03-17 00:45:05 +05:30
|
|
|
&TCB_SYMLINKS;
|
|
|
|
&USE_TCB;
|
* man/login.defs.d/CONSOLE_GROUPS.xml,
man/login.defs.d/CONSOLE.xml, man/login.defs.d/DEFAULT_HOME.xml,
man/login.defs.d/ENV_HZ.xml, man/login.defs.d/ENVIRON_FILE.xml,
man/login.defs.d/ENV_PATH.xml, man/login.defs.d/ENV_SUPATH.xml,
man/login.defs.d/ENV_TZ.xml, man/login.defs.d/ERASECHAR.xml,
man/login.defs.d/FAIL_DELAY.xml,
man/login.defs.d/FAILLOG_ENAB.xml,
man/login.defs.d/FAKE_SHELL.xml, man/login.defs.d/FTMP_FILE.xml,
man/login.defs.d/HUSHLOGIN_FILE.xml,
man/login.defs.d/ISSUE_FILE.xml, man/login.defs.d/KILLCHAR.xml,
man/login.defs.d/LASTLOG_ENAB.xml, man/login.defs.d/LOGIN_RETRIES.xml,
man/login.defs.d/LOGIN_TIMEOUT.xml, man/login.defs.d/LOG_OK_LOGINS.xml,
man/login.defs.d/LOG_UNKFAIL_ENAB.xml,
man/login.defs.d/MAIL_CHECK_ENAB.xml, man/login.defs.d/MOTD_FILE.xml,
man/login.defs.d/NOLOGINS_FILE.xml,
man/login.defs.d/OBSCURE_CHECKS_ENAB.xml,
man/login.defs.d/PASS_ALWAYS_WARN.xml,
man/login.defs.d/PASS_CHANGE_TRIES.xml,
man/login.defs.d/PASS_MAX_LEN.xml,
man/login.defs.d/PORTTIME_CHECKS_ENAB.xml,
man/login.defs.d/QUOTAS_ENAB.xml, man/login.defs.d/SULOG_FILE.xml,
man/login.defs.d/SU_NAME.xml, man/login.defs.d/SU_WHEEL_ONLY.xml,
man/login.defs.d/SYSLOG_SG_ENAB.xml,
man/login.defs.d/SYSLOG_SU_ENAB.xml,
man/login.defs.d/TTYGROUP.xml, man/login.defs.d/TTYTYPE_FILE.xml,
man/login.defs.d/ULIMIT.xml, man/login.defs.d/USERGROUPS_ENAB.xml:
New documentation of login.defs variables.
* man/login.defs.d/MAIL_DIR.xml: Updated. It now contains the
MAIL_FILE documentation.
* man/login.defs.d/LOGIN_STRING.xml: Updated. Mentions %s.
* man/pwconv.8.xml, man/groupmems.8.xml, man/groupdel.8.xml,
man/useradd.8.xml, man/pwck.8.xml, man/groupadd.8.xml,
man/sulogin.8.xml, man/newgrp.1.xml, man/usermod.8.xml,
man/su.1.xml, man/vipw.8.xml, man/passwd.1.xml,
man/groupmod.8.xml, man/login.1.xml, man/userdel.8.xml,
man/grpck.8.xml: Added CONFIGURATION section.
* man/generate_mans.mak: The generations of manpages depends on
the variables from the Makefiles. Add the dependency on Makefile.
* man/login.defs.5.xml: New login.defs variable documented.
* man/Makefile.am: Added XML variable documentation to the
distributed files.
2007-12-09 04:54:40 +05:30
|
|
|
</variablelist>
|
|
|
|
</refsect1>
|
|
|
|
|
2007-10-07 17:16:16 +05:30
|
|
|
<refsect1 id='files'>
|
|
|
|
<title>FILES</title>
|
|
|
|
<variablelist>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term><filename>/etc/group</filename></term>
|
|
|
|
<listitem>
|
2022-03-07 05:42:13 +05:30
|
|
|
<para>Group account information</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2009-05-21 17:32:12 +05:30
|
|
|
<varlistentry condition="gshadow">
|
|
|
|
<term><filename>/etc/gshadow</filename></term>
|
|
|
|
<listitem>
|
2022-12-30 17:21:29 +05:30
|
|
|
<para>Secure group account information</para>
|
2009-05-21 17:32:12 +05:30
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2011-11-19 20:03:53 +05:30
|
|
|
<varlistentry>
|
|
|
|
<term><filename>/etc/login.defs</filename></term>
|
|
|
|
<listitem>
|
2022-03-07 05:42:13 +05:30
|
|
|
<para>Shadow password suite configuration</para>
|
2011-11-19 20:03:53 +05:30
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2007-10-07 17:16:16 +05:30
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term><filename>/etc/passwd</filename></term>
|
|
|
|
<listitem>
|
2022-03-07 05:42:13 +05:30
|
|
|
<para>User account information</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
|
|
|
<varlistentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<term><filename>/etc/shadow</filename></term>
|
|
|
|
<listitem>
|
2022-03-07 05:42:13 +05:30
|
|
|
<para>Secure user account information</para>
|
2007-10-07 17:17:01 +05:30
|
|
|
</listitem>
|
2007-10-07 17:16:16 +05:30
|
|
|
</varlistentry>
|
2013-08-11 19:35:26 +05:30
|
|
|
<varlistentry condition="subids">
|
|
|
|
<term><filename>/etc/subgid</filename></term>
|
|
|
|
<listitem>
|
2022-03-07 05:42:13 +05:30
|
|
|
<para>Per user subordinate group IDs</para>
|
2013-08-11 19:35:26 +05:30
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
|
|
|
<varlistentry condition="subids">
|
|
|
|
<term><filename>/etc/subuid</filename></term>
|
|
|
|
<listitem>
|
2022-03-07 05:42:13 +05:30
|
|
|
<para>Per user subordinate user IDs</para>
|
2013-08-11 19:35:26 +05:30
|
|
|
</listitem>
|
|
|
|
</varlistentry>
|
2007-10-07 17:16:16 +05:30
|
|
|
</variablelist>
|
|
|
|
</refsect1>
|
|
|
|
|
|
|
|
<refsect1 id='see_also'>
|
|
|
|
<title>SEE ALSO</title>
|
2007-10-07 17:17:01 +05:30
|
|
|
<para>
|
|
|
|
<citerefentry>
|
|
|
|
<refentrytitle>chfn</refentrytitle><manvolnum>1</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>chsh</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>crypt</refentrytitle><manvolnum>3</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
2007-10-07 17:16:34 +05:30
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>gpasswd</refentrytitle><manvolnum>8</manvolnum>
|
2007-10-07 17:16:34 +05:30
|
|
|
</citerefentry>,
|
2007-10-07 17:16:16 +05:30
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>groupadd</refentrytitle><manvolnum>8</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>groupdel</refentrytitle><manvolnum>8</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>groupmod</refentrytitle><manvolnum>8</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>login.defs</refentrytitle><manvolnum>5</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>,
|
Allow disabling of subordinate IDs.
* configure.in: Add configure options --enable-subordinate-ids /
--disable-subordinate-ids. Enabled by default.
* lib/prototypes.h: Include <config.h> before using its macros.
* lib/commonio.h, lib/commonio.c: Define commonio_append only when
ENABLE_SUBIDS is defined.
* lib/prototypes.h, libmisc/find_new_sub_gids.c,
libmisc/find_new_sub_uids.c: Likewise.
* lib/subordinateio.h, lib/subordinateio.c: Likewise.
* libmisc/user_busy.c: Only check if subordinate IDs are in use if
ENABLE_SUBIDS is defined.
* src/Makefile.am: Create newgidmap and newuidmap only if
ENABLE_SUBIDS is defined.
* src/newusers.c: Check for ENABLE_SUBIDS to enable support for
subordinate IDs.
* src/useradd.c: Likewise.
* src/userdel.c: Likewise.
* src/usermod.c: Likewise.
* man/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 only if ENABLE_SUBIDS is defined.
* man/fr/Makefile.am: Install man1/newgidmap.1, man1/newuidmap.1,
man5/subgid.5, and man5/subuid.5 (not translated yet).
* man/generate_mans.mak: Add xsltproc conditionals
subids/no_subids.
* man/login.defs.d/SUB_GID_COUNT.xml: Add dependency on subids
condition.
* man/login.defs.d/SUB_UID_COUNT.xml: Likewise.
* man/usermod.8.xml: Document options for subordinate IDs and
reference subgid(5) / subuid(5) depending on the subids condition.
2013-08-11 18:24:22 +05:30
|
|
|
<phrase condition="subids">
|
|
|
|
<citerefentry>
|
|
|
|
<refentrytitle>subgid</refentrytitle><manvolnum>5</manvolnum>
|
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
|
|
|
<refentrytitle>subuid</refentrytitle><manvolnum>5</manvolnum>
|
|
|
|
</citerefentry>,
|
|
|
|
</phrase>
|
2007-10-07 17:16:16 +05:30
|
|
|
<citerefentry>
|
2007-10-07 17:17:01 +05:30
|
|
|
<refentrytitle>useradd</refentrytitle><manvolnum>8</manvolnum>
|
|
|
|
</citerefentry>,
|
|
|
|
<citerefentry>
|
|
|
|
<refentrytitle>userdel</refentrytitle><manvolnum>8</manvolnum>
|
2007-10-07 17:16:16 +05:30
|
|
|
</citerefentry>.
|
|
|
|
</para>
|
|
|
|
</refsect1>
|
|
|
|
</refentry>
|