shadow/man/login.1.xml

229 lines
8.3 KiB
XML

<?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.1'>
<!-- $Id: login.1.xml,v 1.9 2005/06/15 12:39:27 kloczek Exp $ -->
<refmeta>
<refentrytitle>LOGIN</refentrytitle>
<manvolnum>1</manvolnum>
<refmiscinfo class="sectdesc">User Commands</refmiscinfo>
</refmeta>
<refnamediv id='name'>
<refname>login</refname>
<refpurpose>begin session on the system</refpurpose>
</refnamediv>
<!-- body begins here -->
<refsynopsisdiv id='synopsis'>
<cmdsynopsis>
<command>login</command>
<arg choice='opt'>-p </arg>
<arg choice='opt'>
<replaceable>username</replaceable></arg>
<arg choice='opt' rep='repeat'> <replaceable>ENV=VAR</replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<command>login</command>
<arg choice='opt'>-p </arg>
<arg choice='opt'>-h <replaceable>host</replaceable></arg>
<arg choice='opt'>-f <replaceable>username</replaceable></arg>
</cmdsynopsis>
<cmdsynopsis>
<command>login</command>
<arg choice='opt'>-p </arg>
<arg choice='plain'>-r <replaceable>host</replaceable></arg>
</cmdsynopsis>
</refsynopsisdiv>
<refsect1 id='description'>
<title>DESCRIPTION</title>
<para><command>login</command> is used to establish a new session with the
system. It is normally invoked automatically by responding to the
<emphasis remap='I'>login:</emphasis> prompt on the user&acute;s
terminal. <command>login</command> may be special to the shell and may
not be invoked as a sub-process. Typically, <command>login</command>
is treated by the shell as <emphasis remap='B'>exec login</emphasis>
which causes the user to exit from the current shell. Attempting to
execute <command>login</command> from any shell but the login shell
will produce an error message.
</para>
<para>The user is then prompted for a password, where appropriate.
Echoing is disabled to prevent revealing the password. Only a small
number of password failures are permitted before
<command>login</command> exits and the communications link is severed.
</para>
<para>If password aging has been enabled for your account, you may be
prompted for a new password before proceeding. You will be forced to
provide your old password and the new password before continuing.
Please refer to <citerefentry>
<refentrytitle>passwd</refentrytitle><manvolnum>1</manvolnum>
</citerefentry> for more information.
</para>
<para>After a successful login, you will be informed of any system
messages and the presence of mail. You may turn off the printing of
the system message file, <filename>/etc/motd</filename>, by creating a
zero-length file <markup>.hushlogin</markup> in your login directory.
The mail message will be one of "<emphasis remap='B'>You have new
mail.</emphasis> ", "<emphasis remap='B'>You have mail.</emphasis>",
or "<emphasis remap='B'>No Mail.</emphasis> "according to the
condition of your mailbox.
</para>
<para>Your user and group ID will be set according to their values in
the <filename>/etc/passwd</filename> file. The value for <emphasis
remap='B'>$HOME</emphasis>, <emphasis remap='B'>$SHELL</emphasis>,
<emphasis remap='B'>$PATH</emphasis>, <emphasis remap='B'>$LOGNAME</emphasis>,
and <emphasis remap='B'>$MAIL</emphasis> are set according to the
appropriate fields in the password entry. Ulimit, umask and nice
values may also be set according to entries in the GECOS field.
</para>
<para>On some installations, the environmental variable <emphasis
remap='B'>$TERM</emphasis> will be initialized to the terminal type on
your tty line, as specified in <filename>/etc/ttytype</filename>.
</para>
<para>An initialization script for your command interpreter may also be
executed. Please see the appropriate manual section for more
information on
this function.
</para>
<para>A subsystem login is indicated by the presence of a "*" as the
first character of the login shell. The given home directory will be
used as the root of a new file system which the user is actually
logged into.
</para>
</refsect1>
<refsect1 id='options'>
<title>OPTIONS</title>
<variablelist remap='IP'>
<varlistentry>
<term>
<option>-f</option>
</term>
<listitem>
<para>Do not perform authentication, user is preauthenticated.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<option>-h</option>
</term>
<listitem>
<para>Name of the remote host for this login.</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<option>-p</option>
</term>
<listitem>
<para>Preserve environment.</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<option>-r</option>
</term>
<listitem>
<para>Perform autologin protocol for rlogin.</para>
</listitem>
</varlistentry>
</variablelist>
<para>The <option>-r</option>, <option>-h</option> and
<option>-f</option> options are only used when
<command>login</command> is invoked by root.
</para>
</refsect1>
<refsect1 id='caveats'>
<title>CAVEATS</title>
<para>
This version of <command>login</command> has many compilation options,
only some of which may be in use at any particular site.
</para>
<para>The location of files is subject to differences in system
configuration.
</para>
</refsect1>
<refsect1 id='files'>
<title>FILES</title>
<variablelist>
<varlistentry>
<term><filename>/var/run/utmp</filename></term>
<listitem>list of current login sessions</listitem>
</varlistentry>
<varlistentry>
<term><filename>/var/log/wtmp</filename></term>
<listitem>list of previous login sessions</listitem>
</varlistentry>
<varlistentry>
<term><filename>/etc/passwd</filename></term>
<listitem>user account information</listitem>
</varlistentry>
<varlistentry>
<term><filename>/etc/shadow</filename></term>
<listitem>secure user account information</listitem>
</varlistentry>
<varlistentry>
<term><filename>/etc/motd</filename></term>
<listitem>system message of the day file</listitem>
</varlistentry>
<varlistentry>
<term><filename>/etc/nologin</filename></term>
<listitem>prevent non-root users from logging in</listitem>
</varlistentry>
<varlistentry>
<term><filename>/etc/ttytype</filename></term>
<listitem>list of terminal types</listitem>
</varlistentry>
<varlistentry>
<term><filename>$HOME/.hushlogin</filename></term>
<listitem>suppress printing of system messages</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1 id='see_also'>
<title>SEE ALSO</title>
<para><citerefentry>
<refentrytitle>mail</refentrytitle><manvolnum>1</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>passwd</refentrytitle><manvolnum>1</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>sh</refentrytitle><manvolnum>1</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>su</refentrytitle><manvolnum>1</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>login.defs</refentrytitle><manvolnum>5</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>nologin</refentrytitle><manvolnum>5</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>passwd</refentrytitle><manvolnum>5</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>getty</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>
</para>
</refsect1>
<refsect1 id='author'>
<title>AUTHOR</title>
<para>Julianne Frances Haugh &lt;jockgrrl@ix.netcom.com&gt;</para>
</refsect1>
</refentry>