| 1 |
<refentry xmlns="http://docbook.org/ns/docbook" version="5.0" xml:id="pam_pwhistory"> |
| 2 |
|
| 3 |
<refmeta> |
| 4 |
<refentrytitle>pam_pwhistory</refentrytitle> |
| 5 |
<manvolnum>8</manvolnum> |
| 6 |
<refmiscinfo class="source">Linux-PAM</refmiscinfo> |
| 7 |
<refmiscinfo class="manual">Linux-PAM Manual</refmiscinfo> |
| 8 |
</refmeta> |
| 9 |
|
| 10 |
<refnamediv xml:id="pam_pwhistory-name"> |
| 11 |
<refname>pam_pwhistory</refname> |
| 12 |
<refpurpose>PAM module to remember last passwords</refpurpose> |
| 13 |
</refnamediv> |
| 14 |
|
| 15 |
<refsynopsisdiv> |
| 16 |
<cmdsynopsis xml:id="pam_pwhistory-cmdsynopsis" sepchar=" "> |
| 17 |
<command>pam_pwhistory.so</command> |
| 18 |
<arg choice="opt" rep="norepeat"> |
| 19 |
debug |
| 20 |
</arg> |
| 21 |
<arg choice="opt" rep="norepeat"> |
| 22 |
use_authtok |
| 23 |
</arg> |
| 24 |
<arg choice="opt" rep="norepeat"> |
| 25 |
enforce_for_root |
| 26 |
</arg> |
| 27 |
<arg choice="opt" rep="norepeat"> |
| 28 |
remember=<replaceable>N</replaceable> |
| 29 |
</arg> |
| 30 |
<arg choice="opt" rep="norepeat"> |
| 31 |
retry=<replaceable>N</replaceable> |
| 32 |
</arg> |
| 33 |
<arg choice="opt" rep="norepeat"> |
| 34 |
authtok_type=<replaceable>STRING</replaceable> |
| 35 |
</arg> |
| 36 |
<arg choice="opt" rep="norepeat"> |
| 37 |
file=<replaceable>/path/filename</replaceable> |
| 38 |
</arg> |
| 39 |
<arg choice="opt" rep="norepeat"> |
| 40 |
conf=<replaceable>/path/to/config-file</replaceable> |
| 41 |
</arg> |
| 42 |
|
| 43 |
</cmdsynopsis> |
| 44 |
</refsynopsisdiv> |
| 45 |
|
| 46 |
<refsect1 xml:id="pam_pwhistory-description"> |
| 47 |
|
| 48 |
<title>DESCRIPTION</title> |
| 49 |
|
| 50 |
<para> |
| 51 |
This module saves the last passwords for each user in order |
| 52 |
to force password change history and keep the user from |
| 53 |
alternating between the same password too frequently. |
| 54 |
</para> |
| 55 |
<para> |
| 56 |
This module does not work together with kerberos. In general, |
| 57 |
it does not make much sense to use this module in conjunction |
| 58 |
with NIS or LDAP, since the old passwords are stored on the |
| 59 |
local machine and are not available on another machine for |
| 60 |
password history checking. |
| 61 |
</para> |
| 62 |
</refsect1> |
| 63 |
|
| 64 |
<refsect1 xml:id="pam_pwhistory-options"> |
| 65 |
<title>OPTIONS</title> |
| 66 |
<variablelist> |
| 67 |
<varlistentry> |
| 68 |
<term> |
| 69 |
debug |
| 70 |
</term> |
| 71 |
<listitem> |
| 72 |
<para> |
| 73 |
Turns on debugging via |
| 74 |
<citerefentry> |
| 75 |
<refentrytitle>syslog</refentrytitle><manvolnum>3</manvolnum> |
| 76 |
</citerefentry>. |
| 77 |
</para> |
| 78 |
</listitem> |
| 79 |
</varlistentry> |
| 80 |
<varlistentry> |
| 81 |
<term> |
| 82 |
use_authtok |
| 83 |
</term> |
| 84 |
<listitem> |
| 85 |
<para> |
| 86 |
When password changing enforce the module to use the new password |
| 87 |
provided by a previously stacked <option>password</option> |
| 88 |
module (this is used in the example of the stacking of the |
| 89 |
<command>pam_passwdqc</command> module documented below). |
| 90 |
</para> |
| 91 |
</listitem> |
| 92 |
</varlistentry> |
| 93 |
<varlistentry> |
| 94 |
<term> |
| 95 |
enforce_for_root |
| 96 |
</term> |
| 97 |
<listitem> |
| 98 |
<para> |
| 99 |
If this option is set, the check is enforced for root, too. |
| 100 |
</para> |
| 101 |
</listitem> |
| 102 |
</varlistentry> |
| 103 |
<varlistentry> |
| 104 |
<term> |
| 105 |
remember=N |
| 106 |
</term> |
| 107 |
<listitem> |
| 108 |
<para> |
| 109 |
The last <replaceable>N</replaceable> passwords for each |
| 110 |
user are saved. |
| 111 |
The default is <emphasis>10</emphasis>. Value of |
| 112 |
<emphasis>0</emphasis> makes the module to keep the existing |
| 113 |
contents of the <filename>opasswd</filename> file unchanged. |
| 114 |
</para> |
| 115 |
</listitem> |
| 116 |
</varlistentry> |
| 117 |
<varlistentry> |
| 118 |
<term> |
| 119 |
retry=N |
| 120 |
</term> |
| 121 |
<listitem> |
| 122 |
<para> |
| 123 |
Prompt user at most <replaceable>N</replaceable> times |
| 124 |
before returning with error. The default is |
| 125 |
<emphasis>1</emphasis>. |
| 126 |
</para> |
| 127 |
</listitem> |
| 128 |
</varlistentry> |
| 129 |
|
| 130 |
<varlistentry> |
| 131 |
<term> |
| 132 |
authtok_type=STRING |
| 133 |
</term> |
| 134 |
<listitem> |
| 135 |
<para> |
| 136 |
See <citerefentry> |
| 137 |
<refentrytitle>pam_get_authtok</refentrytitle><manvolnum>3</manvolnum> |
| 138 |
</citerefentry> for more details. |
| 139 |
</para> |
| 140 |
</listitem> |
| 141 |
</varlistentry> |
| 142 |
|
| 143 |
<varlistentry> |
| 144 |
<term> |
| 145 |
file=/path/filename |
| 146 |
</term> |
| 147 |
<listitem> |
| 148 |
<para> |
| 149 |
Store password history in file <filename>/path/filename</filename> |
| 150 |
rather than the default location. The default location is |
| 151 |
<filename>/etc/security/opasswd</filename>. |
| 152 |
</para> |
| 153 |
</listitem> |
| 154 |
</varlistentry> |
| 155 |
|
| 156 |
<varlistentry> |
| 157 |
<term> |
| 158 |
conf=/path/to/config-file |
| 159 |
</term> |
| 160 |
<listitem> |
| 161 |
<para> |
| 162 |
Use another configuration file instead of the default |
| 163 |
<filename>/etc/security/pwhistory.conf</filename>. |
| 164 |
</para> |
| 165 |
</listitem> |
| 166 |
</varlistentry> |
| 167 |
|
| 168 |
</variablelist> |
| 169 |
<para> |
| 170 |
The options for configuring the module behavior are described in the |
| 171 |
<citerefentry><refentrytitle>pwhistory.conf</refentrytitle> |
| 172 |
<manvolnum>5</manvolnum></citerefentry> manual page. The options |
| 173 |
specified on the module command line override the values from the |
| 174 |
configuration file. |
| 175 |
</para> |
| 176 |
</refsect1> |
| 177 |
|
| 178 |
<refsect1 xml:id="pam_pwhistory-types"> |
| 179 |
<title>MODULE TYPES PROVIDED</title> |
| 180 |
<para> |
| 181 |
Only the <option>password</option> module type is provided. |
| 182 |
</para> |
| 183 |
</refsect1> |
| 184 |
|
| 185 |
<refsect1 xml:id="pam_pwhistory-return_values"> |
| 186 |
<title>RETURN VALUES</title> |
| 187 |
<variablelist> |
| 188 |
<varlistentry> |
| 189 |
<term>PAM_AUTHTOK_ERR</term> |
| 190 |
<listitem> |
| 191 |
<para> |
| 192 |
No new password was entered, the user aborted password |
| 193 |
change or new password couldn't be set. |
| 194 |
</para> |
| 195 |
</listitem> |
| 196 |
</varlistentry> |
| 197 |
<varlistentry> |
| 198 |
<term>PAM_IGNORE</term> |
| 199 |
<listitem> |
| 200 |
<para> |
| 201 |
Password history was disabled. |
| 202 |
</para> |
| 203 |
</listitem> |
| 204 |
</varlistentry> |
| 205 |
<varlistentry> |
| 206 |
<term>PAM_MAXTRIES</term> |
| 207 |
<listitem> |
| 208 |
<para> |
| 209 |
Password was rejected too often. |
| 210 |
</para> |
| 211 |
</listitem> |
| 212 |
</varlistentry> |
| 213 |
<varlistentry> |
| 214 |
<term>PAM_USER_UNKNOWN</term> |
| 215 |
<listitem> |
| 216 |
<para> |
| 217 |
User is not known to system. |
| 218 |
</para> |
| 219 |
</listitem> |
| 220 |
</varlistentry> |
| 221 |
</variablelist> |
| 222 |
</refsect1> |
| 223 |
|
| 224 |
<refsect1 xml:id="pam_pwhistory-examples"> |
| 225 |
<title>EXAMPLES</title> |
| 226 |
<para> |
| 227 |
An example password section would be: |
| 228 |
<programlisting> |
| 229 |
#%PAM-1.0 |
| 230 |
password required pam_pwhistory.so |
| 231 |
password required pam_unix.so use_authtok |
| 232 |
</programlisting> |
| 233 |
</para> |
| 234 |
<para> |
| 235 |
In combination with <command>pam_passwdqc</command>: |
| 236 |
<programlisting> |
| 237 |
#%PAM-1.0 |
| 238 |
password required pam_passwdqc.so config=/etc/passwdqc.conf |
| 239 |
password required pam_pwhistory.so use_authtok |
| 240 |
password required pam_unix.so use_authtok |
| 241 |
</programlisting> |
| 242 |
</para> |
| 243 |
</refsect1> |
| 244 |
|
| 245 |
<refsect1 xml:id="pam_pwhistory-files"> |
| 246 |
<title>FILES</title> |
| 247 |
<variablelist> |
| 248 |
<varlistentry> |
| 249 |
<term>/etc/security/opasswd</term> |
| 250 |
<listitem> |
| 251 |
<para>Default file with password history</para> |
| 252 |
</listitem> |
| 253 |
</varlistentry> |
| 254 |
<varlistentry> |
| 255 |
<term><filename>/etc/security/pwhistory.conf</filename></term> |
| 256 |
<listitem> |
| 257 |
<para>Config file for pam_pwhistory options</para> |
| 258 |
</listitem> |
| 259 |
</varlistentry> |
| 260 |
<varlistentry condition="with_vendordir"> |
| 261 |
<term><filename>%vendordir%/security/pwhistory.conf</filename></term> |
| 262 |
<listitem> |
| 263 |
<para> |
| 264 |
Config file for pam_pwhistory options. It will be used if |
| 265 |
<filename>/etc/security/pwhistory.conf</filename> does not exist. |
| 266 |
</para> |
| 267 |
</listitem> |
| 268 |
</varlistentry> |
| 269 |
</variablelist> |
| 270 |
</refsect1> |
| 271 |
|
| 272 |
<refsect1 xml:id="pam_pwhistory-see_also"> |
| 273 |
<title>SEE ALSO</title> |
| 274 |
<para> |
| 275 |
<citerefentry> |
| 276 |
<refentrytitle>pwhistory.conf</refentrytitle><manvolnum>5</manvolnum> |
| 277 |
</citerefentry>, |
| 278 |
<citerefentry> |
| 279 |
<refentrytitle>pam.conf</refentrytitle><manvolnum>5</manvolnum> |
| 280 |
</citerefentry>, |
| 281 |
<citerefentry> |
| 282 |
<refentrytitle>pam.d</refentrytitle><manvolnum>5</manvolnum> |
| 283 |
</citerefentry>, |
| 284 |
<citerefentry> |
| 285 |
<refentrytitle>pam</refentrytitle><manvolnum>8</manvolnum> |
| 286 |
</citerefentry> |
| 287 |
<citerefentry> |
| 288 |
<refentrytitle>pam_get_authtok</refentrytitle><manvolnum>3</manvolnum> |
| 289 |
</citerefentry> |
| 290 |
</para> |
| 291 |
</refsect1> |
| 292 |
|
| 293 |
<refsect1 xml:id="pam_pwhistory-author"> |
| 294 |
<title>AUTHOR</title> |
| 295 |
<para> |
| 296 |
pam_pwhistory was written by Thorsten Kukuk <[email protected]> |
| 297 |
</para> |
| 298 |
</refsect1> |
| 299 |
|
| 300 |
</refentry> |