2007-10-07 17:15:40 +05:30
|
|
|
.\"$Id: login.1,v 1.17 2004/08/04 13:02:23 kloczek Exp $
|
2007-10-07 17:14:44 +05:30
|
|
|
.\" Copyright 1989 - 1994, Julianne Frances Haugh
|
|
|
|
.\" All rights reserved.
|
|
|
|
.\"
|
|
|
|
.\" Redistribution and use in source and binary forms, with or without
|
|
|
|
.\" modification, are permitted provided that the following conditions
|
|
|
|
.\" are met:
|
|
|
|
.\" 1. Redistributions of source code must retain the above copyright
|
|
|
|
.\" notice, this list of conditions and the following disclaimer.
|
|
|
|
.\" 2. Redistributions in binary form must reproduce the above copyright
|
|
|
|
.\" notice, this list of conditions and the following disclaimer in the
|
|
|
|
.\" documentation and/or other materials provided with the distribution.
|
|
|
|
.\" 3. Neither the name of Julianne F. Haugh nor the names of its contributors
|
|
|
|
.\" may be used to endorse or promote products derived from this software
|
|
|
|
.\" without specific prior written permission.
|
|
|
|
.\"
|
|
|
|
.\" THIS SOFTWARE IS PROVIDED BY JULIE HAUGH AND CONTRIBUTORS ``AS IS'' AND
|
|
|
|
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
|
|
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
|
|
.\" ARE DISCLAIMED. IN NO EVENT SHALL JULIE HAUGH OR CONTRIBUTORS BE LIABLE
|
|
|
|
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
|
|
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|
|
|
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
|
|
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
|
|
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|
|
|
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
|
|
.\" SUCH DAMAGE.
|
|
|
|
.TH LOGIN 1
|
|
|
|
.SH NAME
|
2007-10-07 17:15:14 +05:30
|
|
|
login \- begin session on the system
|
2007-10-07 17:14:44 +05:30
|
|
|
.SH SYNOPSIS
|
2007-10-07 17:15:14 +05:30
|
|
|
\fBlogin\fR [\fB-p\fR] [\fIusername\fR] [\fIENV=VAR\fR ...]
|
2007-10-07 17:14:44 +05:30
|
|
|
.br
|
2007-10-07 17:15:14 +05:30
|
|
|
\fBlogin\fR [\fB-p\fR] [\fB-h \fIhost\fR] [\fB-f \fIusername\fR]
|
2007-10-07 17:14:44 +05:30
|
|
|
.br
|
2007-10-07 17:15:14 +05:30
|
|
|
\fBlogin\fR [\fB-p\fR] \fB-r \fIhost\fR
|
2007-10-07 17:14:44 +05:30
|
|
|
.SH DESCRIPTION
|
2007-10-07 17:15:23 +05:30
|
|
|
\fBlogin\fR is used to establish a new session with the system. It is
|
|
|
|
normally invoked automatically by responding to the \fIlogin:\fR prompt on
|
|
|
|
the user\'s terminal. fBlogin\fR may be special to the shell and may not be
|
|
|
|
invoked as a sub-process. Typically, \fBlogin\fR is treated by the shell as
|
|
|
|
\fBexec login\fR which causes the user to exit from the current shell.
|
|
|
|
Attempting to execute \fBlogin\fR from any shell but the login shell will
|
|
|
|
produce an error message.
|
2007-10-07 17:14:44 +05:30
|
|
|
.PP
|
2007-10-07 17:15:23 +05:30
|
|
|
|
|
|
|
When invoked from the \fIlogin:\fR prompt, the user may enter environmental
|
|
|
|
variables after the username. These variables are entered in the form
|
|
|
|
\fBNAME=VALUE\fR. Not all variables may be set in the fashion, notably
|
|
|
|
\fBPATH\fR, \fBHOME\fR and \fBSHELL\fR. Additionally, \fBIFS\fR may be
|
|
|
|
inhibited if the user\'s login shell is \fB/bin/sh\fR.
|
2007-10-07 17:14:44 +05:30
|
|
|
.PP
|
2007-10-07 17:15:23 +05:30
|
|
|
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 \fBlogin\fR exits and the communications link
|
|
|
|
is severed.
|
2007-10-07 17:14:44 +05:30
|
|
|
.PP
|
2007-10-07 17:15:23 +05:30
|
|
|
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
|
|
|
|
\fBpasswd\fR(1) for more information.
|
2007-10-07 17:14:44 +05:30
|
|
|
.PP
|
2007-10-07 17:15:23 +05:30
|
|
|
|
|
|
|
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, \fI/etc/motd\fR, by creating a zero-length file \fI.hushlogin\fR in
|
|
|
|
your login directory. The mail message will be one of "\fBYou have new
|
|
|
|
mail.\fR", "\fBYou have mail.\fR", or "\fBNo Mail.\fR" according to the
|
|
|
|
condition of your mailbox.
|
|
|
|
|
2007-10-07 17:14:44 +05:30
|
|
|
.PP
|
|
|
|
Your user and group ID will be set according to their values in
|
|
|
|
the \fI/etc/passwd\fR file.
|
|
|
|
The value for \fB$HOME\fR, \fB$SHELL\fR, \fB$PATH\fR, \fB$LOGNAME\fR,
|
|
|
|
and \fB$MAIL\fR 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.
|
|
|
|
.PP
|
|
|
|
On some installations, the environmental variable \fB$TERM\fR will be
|
2007-10-07 17:15:14 +05:30
|
|
|
initialized to the terminal type on your tty line, as specified in
|
2007-10-07 17:14:44 +05:30
|
|
|
\fI/etc/ttytype\fR.
|
|
|
|
.PP
|
|
|
|
An initialization script for your command interpreter may also be
|
|
|
|
executed.
|
|
|
|
Please see the appropriate manual section for more information on
|
|
|
|
this function.
|
|
|
|
.PP
|
|
|
|
A subsystem login is indicated by the presense of a "*" as the first
|
|
|
|
character of the login shell. The given home directory will be used as
|
|
|
|
the root of a new filesystem which the user is actually logged into.
|
|
|
|
.SH OPTIONS
|
2007-10-07 17:15:23 +05:30
|
|
|
.IP "\fB-f\fR"
|
2007-10-07 17:14:44 +05:30
|
|
|
Do not perform authentication, user is preauthenticated.
|
2007-10-07 17:15:23 +05:30
|
|
|
.IP "\fB-h\fR"
|
2007-10-07 17:14:44 +05:30
|
|
|
Name of the remote host for this login.
|
2007-10-07 17:15:40 +05:30
|
|
|
.IP "\fB-p\fR"
|
|
|
|
Preserve environment.
|
2007-10-07 17:15:23 +05:30
|
|
|
.IP "\fB-r\fR"
|
2007-10-07 17:14:44 +05:30
|
|
|
Perform autologin protocol for rlogin.
|
|
|
|
.PP
|
2007-10-07 17:15:14 +05:30
|
|
|
The \fB-r\fP, \fB-h\fP and \fB-f\fP options are only used when \fBlogin\fP is
|
|
|
|
invoked by root.
|
2007-10-07 17:14:44 +05:30
|
|
|
.SH CAVEATS
|
|
|
|
This version of \fBlogin\fR has many compilation options, only some of which
|
|
|
|
may be in use at any particular site.
|
|
|
|
.PP
|
|
|
|
The location of files is subject to differences in system configuration.
|
|
|
|
.SH FILES
|
2007-10-07 17:15:23 +05:30
|
|
|
\fI/var/run/utmp\fR \- list of current login sessions
|
2007-10-07 17:15:14 +05:30
|
|
|
.br
|
2007-10-07 17:15:23 +05:30
|
|
|
\fI/var/log/wtmp\fR \- list of previous login sessions
|
2007-10-07 17:14:44 +05:30
|
|
|
.br
|
2007-10-07 17:15:23 +05:30
|
|
|
\fI/etc/passwd\fR \- user account information
|
2007-10-07 17:14:44 +05:30
|
|
|
.br
|
2007-10-07 17:15:23 +05:30
|
|
|
\fI/etc/shadow\fR \- encrypted passwords and age information
|
2007-10-07 17:14:44 +05:30
|
|
|
.br
|
2007-10-07 17:15:23 +05:30
|
|
|
\fI/etc/motd\fR \- system message file
|
2007-10-07 17:14:44 +05:30
|
|
|
.br
|
2007-10-07 17:15:23 +05:30
|
|
|
\fI/etc/nologin\fR \- prevent non-root users from logging in
|
2007-10-07 17:14:44 +05:30
|
|
|
.br
|
2007-10-07 17:15:23 +05:30
|
|
|
\fI/etc/ttytype\fR \- list of terminal types
|
2007-10-07 17:14:44 +05:30
|
|
|
.br
|
2007-10-07 17:15:23 +05:30
|
|
|
\fI$HOME/.hushlogin\fR \- suppress printing of system messages
|
2007-10-07 17:14:44 +05:30
|
|
|
.SH SEE ALSO
|
|
|
|
.BR mail (1),
|
|
|
|
.BR passwd (1),
|
|
|
|
.BR sh (1),
|
|
|
|
.BR su (1),
|
2007-10-07 17:15:14 +05:30
|
|
|
.BR login.defs (5),
|
|
|
|
.BR nologin (5),
|
2007-10-07 17:14:44 +05:30
|
|
|
.BR passwd (5),
|
2007-10-07 17:15:14 +05:30
|
|
|
.BR getty (8)
|
2007-10-07 17:14:44 +05:30
|
|
|
.SH AUTHOR
|
2007-10-07 17:15:14 +05:30
|
|
|
Julianne Frances Haugh <jockgrrl@ix.netcom.com>
|