summaryrefslogtreecommitdiff
path: root/usr/src/man/man5/pam_authtok_check.5
blob: 2c6c0f544d5f4e2407882042ff03928d3f516632 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
'\" te
.\" Copyright (C) 2003, Sun Microsystems, Inc.
.\" All Rights Reserved
.\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
.\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
.\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
.TH PAM_AUTHTOK_CHECK 5 "Mar 1, 2005"
.SH NAME
pam_authtok_check \- authentication and password management module
.SH SYNOPSIS
.LP
.nf
\fBpam_authtok_check.so.1\fR
.fi

.SH DESCRIPTION
.sp
.LP
\fBpam_authtok_check\fR provides functionality to the Password Management
stack. The implementation of \fBpam_sm_chauthtok()\fR performs a number of
checks on the construction of the newly entered password.
\fBpam_sm_chauthtok()\fR is invoked twice by the PAM framework, once with flags
set to \fBPAM_PRELIM_CHECK\fR, and once with flags set to
\fBPAM_UPDATE_AUTHTOK\fR. This module only performs its checks during the first
invocation. This module expects the current authentication token in the
\fBPAM_OLDAUTHTOK\fR item, the new (to be checked) password in the
\fBPAM_AUTHTOK\fR item, and the login name in the \fBPAM_USER\fR item. The
checks performed by this module are:
.sp
.ne 2
.na
\fBlength\fR
.ad
.RS 20n
The password length should not be less that the minimum specified in
\fB/etc/default/passwd\fR.
.RE

.sp
.ne 2
.na
\fBcircular shift\fR
.ad
.RS 20n
The password should not be a circular shift of the login name. This check may
be disabled in \fB/etc/default/passwd\fR.
.RE

.sp
.ne 2
.na
\fBcomplexity\fR
.ad
.RS 20n
The password should contain at least the minimum number of characters described
by the parameters \fBMINALPHA\fR, \fBMINNONALPHA\fR, \fBMINDIGIT\fR, and
\fBMINSPECIAL\fR. Note that \fBMINNONALPHA\fR describes the same character
classes as \fBMINDIGIT\fR and \fBMINSPECIAL\fR combined; therefore the user
cannot specify both \fBMINNONALPHA\fR and \fBMINSPECIAL\fR (or \fBMINDIGIT\fR).
The user must choose which of the two options to use. Furthermore, the
\fBWHITESPACE\fR parameter determines whether whitespace characters are
allowed. If unspecified \fBMINALPHA\fR is 2, \fBMINNONALPHA\fR is 1 and
\fBWHITESPACE\fR is yes
.RE

.sp
.ne 2
.na
\fBvariation\fR
.ad
.RS 20n
The old and new passwords must differ by at least the \fBMINDIFF\fR value
specified in \fB/etc/default/passwd\fR. If unspecified, the default is 3. For
accounts in name services which support password history checking, if prior
history is defined, the new password must not match the prior passwords.
.RE

.sp
.ne 2
.na
\fBdictionary check\fR
.ad
.RS 20n
The password must not be based on a dictionary word. The list of words to be
used for the site's dictionary can be specified with \fBDICTIONLIST\fR. It
should contain a comma-separated list of filenames, one word per line. The
database that is created from these files is stored in the directory named by
\fBDICTIONDBDIR\fR (defaults to \fB/var/passwd\fR). See \fBmkpwdict\fR(1M) for
information on pre-generating the database. If neither \fBDICTIONLIST\fR nor
\fBDICTIONDBDIR\fR is specified, no dictionary check is made.
.RE

.sp
.ne 2
.na
\fBupper/lower case\fR
.ad
.RS 20n
The password must contain at least the minimum of upper- and lower-case letters
specified by the \fBMINUPPER\fR and \fBMINLOWER\fR values in
\fB/etc/default/passwd\fR. If unspecified, the defaults are 0.
.RE

.sp
.ne 2
.na
\fBmaximum repeats\fR
.ad
.RS 20n
The password must not contain more consecutively repeating characters than
specified by the \fBMAXREPEATS\fR value in \fB/etc/default/passwd\fR. If
unspecified, no repeat character check is made.
.RE

.sp
.LP
The following option may be passed to the module:
.sp
.ne 2
.na
\fBforce_check\fR
.ad
.RS 15n
If the \fBPAM_NO_AUTHTOK_CHECK\fR flag set, \fBforce_check\fR ignores this
flag. The \fBPAM_NO_AUTHTOK_CHECK\fR flag can be set to bypass password checks
(see \fBpam_chauthtok\fR(3PAM)).
.RE

.sp
.ne 2
.na
\fBdebug\fR
.ad
.RS 15n
\fBsyslog\fR(3C) debugging information at the \fBLOG_DEBUG\fR level
.RE

.SH RETURN VALUES
.sp
.LP
If the password in \fBPAM_AUTHTOK\fR passes all tests, \fBPAM_SUCCESS\fR is
returned. If any of the tests fail, \fBPAM_AUTHTOK_ERR\fR is returned.
.SH FILES
.sp
.ne 2
.na
\fB/etc/default/passwd\fR
.ad
.RS 23n
See \fBpasswd\fR(1) for a description of the contents.
.RE

.SH ATTRIBUTES
.sp
.LP
See \fBattributes\fR(5) for descriptions of the following attributes:
.sp

.sp
.TS
box;
c | c
l | l .
ATTRIBUTE TYPE	ATTRIBUTE VALUE
_
Interface Stability	Evolving
_
MT Level	MT-Safe with exceptions
.TE

.SH SEE ALSO
.sp
.LP
\fBpasswd\fR(1), \fBpam\fR(3PAM), \fBmkpwdict\fR(1M),
\fBpam_chauthtok\fR(3PAM), \fBsyslog\fR(3C), \fBlibpam\fR(3LIB),
\fBpam.conf\fR(4), \fBpasswd\fR(4), \fBshadow\fR(4), \fBattributes\fR(5),
\fBpam_authtok_get\fR(5), \fBpam_authtok_store\fR(5), \fBpam_dhkeys\fR(5),
\fBpam_passwd_auth\fR(5), \fBpam_unix_account\fR(5), \fBpam_unix_auth\fR(5),
\fBpam_unix_session\fR(5)
.SH NOTES
.sp
.LP
The interfaces in \fBlibpam\fR(3LIB) are MT-Safe only if each thread within the
multi-threaded application uses its own \fBPAM\fR handle.
.sp
.LP
The \fBpam_unix\fR(5) module is no longer supported. Similar functionality is
provided by \fBpam_authtok_check\fR(5), \fBpam_authtok_get\fR(5),
\fBpam_authtok_store\fR(5), \fBpam_dhkeys\fR(5), \fBpam_passwd_auth\fR(5),
\fBpam_unix_account\fR(5), \fBpam_unix_auth\fR(5), and
\fBpam_unix_session\fR(5).