aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/nologin
diff options
context:
space:
mode:
authorMateusz Piotrowski <0mp@FreeBSD.org>2020-04-15 13:13:46 +0000
committerMateusz Piotrowski <0mp@FreeBSD.org>2020-04-15 13:13:46 +0000
commit6f2b8776479699a31737be94e47b2b166b82cc13 (patch)
tree42f98cd05791b31bfccd2d69ef7f0d2b8e30c9c9 /usr.sbin/nologin
parent0f3bf682121803fa3dcbe332946966f3b6c36930 (diff)
downloadsrc-6f2b8776479699a31737be94e47b2b166b82cc13.tar.gz
src-6f2b8776479699a31737be94e47b2b166b82cc13.zip
Document the exit status and the stdout message of nologin(8)
Reviewed by: debdrup (earlier version) MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D24196
Notes
Notes: svn path=/head/; revision=359967
Diffstat (limited to 'usr.sbin/nologin')
-rw-r--r--usr.sbin/nologin/nologin.825
1 files changed, 21 insertions, 4 deletions
diff --git a/usr.sbin/nologin/nologin.8 b/usr.sbin/nologin/nologin.8
index ca667ad3c7af..815f5db7561f 100644
--- a/usr.sbin/nologin/nologin.8
+++ b/usr.sbin/nologin/nologin.8
@@ -28,7 +28,7 @@
.\" @(#)nologin.8 8.1 (Berkeley) 6/19/93
.\" $FreeBSD$
.\"
-.Dd June 19, 1993
+.Dd April 15, 2020
.Dt NOLOGIN 8
.Os
.Sh NAME
@@ -39,14 +39,31 @@
.Sh DESCRIPTION
The
.Nm
-utility displays a message that an account is not available and
-exits non-zero.
-It is intended as a replacement shell field for accounts that
+is intended as a replacement shell field for accounts that
have been disabled.
.Pp
+When executed,
+.Nm
+first writes about the login attempt to
+.Xr syslog 3
+and then a displays a message that an account is not available.
+.Pp
To disable all logins,
investigate
.Xr nologin 5 .
+.Sh EXIT STATUS
+The
+.Nm
+utility always exits non-zero.
+.Sh EXAMPLES
+Here is a demonstration of executing
+.Nm :
+.Bd -literal -offset 4n
+$ nologin
+This account is currently not available.
+$ tail -n 1 /var/log/messages
+Mar 30 21:53:07 example.org nologin[65992]: Attempted login by beastie on /dev/pts/18
+.Ed
.Sh SEE ALSO
.Xr login 1 ,
.Xr nologin 5