faillock.conf.5.xml 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253
  1. <?xml version="1.0" encoding='UTF-8'?>
  2. <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
  3. "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
  4. <refentry id="faillock.conf">
  5. <refmeta>
  6. <refentrytitle>faillock.conf</refentrytitle>
  7. <manvolnum>5</manvolnum>
  8. <refmiscinfo class="sectdesc">Linux-PAM Manual</refmiscinfo>
  9. </refmeta>
  10. <refnamediv id="faillock.conf-name">
  11. <refname>faillock.conf</refname>
  12. <refpurpose>pam_faillock configuration file</refpurpose>
  13. </refnamediv>
  14. <refsect1 id="faillock.conf-description">
  15. <title>DESCRIPTION</title>
  16. <para>
  17. <emphasis remap='B'>faillock.conf</emphasis> provides a way to configure the
  18. default settings for locking the user after multiple failed authentication attempts.
  19. This file is read by the <emphasis>pam_faillock</emphasis> module and is the
  20. preferred method over configuring <emphasis>pam_faillock</emphasis> directly.
  21. </para>
  22. <para>
  23. The file has a very simple <emphasis>name = value</emphasis> format with possible comments
  24. starting with <emphasis>#</emphasis> character. The whitespace at the beginning of line, end
  25. of line, and around the <emphasis>=</emphasis> sign is ignored.
  26. </para>
  27. </refsect1>
  28. <refsect1 id="faillock.conf-options">
  29. <title>OPTIONS</title>
  30. <variablelist>
  31. <varlistentry>
  32. <term>
  33. <option>dir=<replaceable>/path/to/tally-directory</replaceable></option>
  34. </term>
  35. <listitem>
  36. <para>
  37. The directory where the user files with the failure records are kept. The
  38. default is <filename>/var/run/faillock</filename>.
  39. </para>
  40. </listitem>
  41. </varlistentry>
  42. <varlistentry>
  43. <term>
  44. <option>audit</option>
  45. </term>
  46. <listitem>
  47. <para>
  48. Will log the user name into the system log if the user is not found.
  49. </para>
  50. </listitem>
  51. </varlistentry>
  52. <varlistentry>
  53. <term>
  54. <option>silent</option>
  55. </term>
  56. <listitem>
  57. <para>
  58. Don't print informative messages to the user. Please note that when
  59. this option is not used there will be difference in the authentication
  60. behavior for users which exist on the system and non-existing users.
  61. </para>
  62. </listitem>
  63. </varlistentry>
  64. <varlistentry>
  65. <term>
  66. <option>no_log_info</option>
  67. </term>
  68. <listitem>
  69. <para>
  70. Don't log informative messages via <citerefentry><refentrytitle>syslog</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
  71. </para>
  72. </listitem>
  73. </varlistentry>
  74. <varlistentry>
  75. <term>
  76. <option>local_users_only</option>
  77. </term>
  78. <listitem>
  79. <para>
  80. Only track failed user authentications attempts for local users
  81. in /etc/passwd and ignore centralized (AD, IdM, LDAP, etc.) users.
  82. The <citerefentry><refentrytitle>faillock</refentrytitle><manvolnum>8</manvolnum></citerefentry>
  83. command will also no longer track user failed
  84. authentication attempts. Enabling this option will prevent a
  85. double-lockout scenario where a user is locked out locally and
  86. in the centralized mechanism.
  87. </para>
  88. </listitem>
  89. </varlistentry>
  90. <varlistentry>
  91. <term>
  92. <option>nodelay</option>
  93. </term>
  94. <listitem>
  95. <para>
  96. Don't enforce a delay after authentication failures.
  97. </para>
  98. </listitem>
  99. </varlistentry>
  100. <varlistentry>
  101. <term>
  102. <option>deny=<replaceable>n</replaceable></option>
  103. </term>
  104. <listitem>
  105. <para>
  106. Deny access if the number of consecutive authentication failures
  107. for this user during the recent interval exceeds
  108. <replaceable>n</replaceable>. The default is 3.
  109. </para>
  110. </listitem>
  111. </varlistentry>
  112. <varlistentry>
  113. <term>
  114. <option>fail_interval=<replaceable>n</replaceable></option>
  115. </term>
  116. <listitem>
  117. <para>
  118. The length of the interval during which the consecutive
  119. authentication failures must happen for the user account
  120. lock out is <replaceable>n</replaceable> seconds.
  121. The default is 900 (15 minutes).
  122. </para>
  123. </listitem>
  124. </varlistentry>
  125. <varlistentry>
  126. <term>
  127. <option>unlock_time=<replaceable>n</replaceable></option>
  128. </term>
  129. <listitem>
  130. <para>
  131. The access will be re-enabled after
  132. <replaceable>n</replaceable> seconds after the lock out.
  133. The value 0 has the same meaning as value
  134. <emphasis>never</emphasis> - the access
  135. will not be re-enabled without resetting the faillock
  136. entries by the <citerefentry><refentrytitle>faillock</refentrytitle><manvolnum>8</manvolnum></citerefentry> command.
  137. The default is 600 (10 minutes).
  138. </para>
  139. <para>
  140. Note that the default directory that <emphasis>pam_faillock</emphasis>
  141. uses is usually cleared on system boot so the access will be also re-enabled
  142. after system reboot. If that is undesirable a different tally directory
  143. must be set with the <option>dir</option> option.
  144. </para>
  145. <para>
  146. Also note that it is usually undesirable to permanently lock
  147. out users as they can become easily a target of denial of service
  148. attack unless the usernames are random and kept secret to potential
  149. attackers.
  150. </para>
  151. </listitem>
  152. </varlistentry>
  153. <varlistentry>
  154. <term>
  155. <option>even_deny_root</option>
  156. </term>
  157. <listitem>
  158. <para>
  159. Root account can become locked as well as regular accounts.
  160. </para>
  161. </listitem>
  162. </varlistentry>
  163. <varlistentry>
  164. <term>
  165. <option>root_unlock_time=<replaceable>n</replaceable></option>
  166. </term>
  167. <listitem>
  168. <para>
  169. This option implies <option>even_deny_root</option> option.
  170. Allow access after <replaceable>n</replaceable> seconds
  171. to root account after the account is locked. In case the
  172. option is not specified the value is the same as of the
  173. <option>unlock_time</option> option.
  174. </para>
  175. </listitem>
  176. </varlistentry>
  177. <varlistentry>
  178. <term>
  179. <option>admin_group=<replaceable>name</replaceable></option>
  180. </term>
  181. <listitem>
  182. <para>
  183. If a group name is specified with this option, members
  184. of the group will be handled by this module the same as
  185. the root account (the options <option>even_deny_root</option>
  186. and <option>root_unlock_time</option> will apply to them.
  187. By default the option is not set.
  188. </para>
  189. </listitem>
  190. </varlistentry>
  191. </variablelist>
  192. </refsect1>
  193. <refsect1 id='faillock.conf-examples'>
  194. <title>EXAMPLES</title>
  195. <para>
  196. /etc/security/faillock.conf file example:
  197. </para>
  198. <programlisting>
  199. deny=4
  200. unlock_time=1200
  201. silent
  202. </programlisting>
  203. </refsect1>
  204. <refsect1 id="faillock.conf-files">
  205. <title>FILES</title>
  206. <variablelist>
  207. <varlistentry>
  208. <term><filename>/etc/security/faillock.conf</filename></term>
  209. <listitem>
  210. <para>the config file for custom options</para>
  211. </listitem>
  212. </varlistentry>
  213. </variablelist>
  214. </refsect1>
  215. <refsect1 id='faillock.conf-see_also'>
  216. <title>SEE ALSO</title>
  217. <para>
  218. <citerefentry>
  219. <refentrytitle>faillock</refentrytitle><manvolnum>8</manvolnum>
  220. </citerefentry>,
  221. <citerefentry>
  222. <refentrytitle>pam_faillock</refentrytitle><manvolnum>8</manvolnum>
  223. </citerefentry>,
  224. <citerefentry>
  225. <refentrytitle>pam.conf</refentrytitle><manvolnum>5</manvolnum>
  226. </citerefentry>,
  227. <citerefentry>
  228. <refentrytitle>pam.d</refentrytitle><manvolnum>5</manvolnum>
  229. </citerefentry>,
  230. <citerefentry>
  231. <refentrytitle>pam</refentrytitle><manvolnum>8</manvolnum>
  232. </citerefentry>
  233. </para>
  234. </refsect1>
  235. <refsect1 id='faillock.conf-author'>
  236. <title>AUTHOR</title>
  237. <para>
  238. pam_faillock was written by Tomas Mraz. The support for faillock.conf was written by Brian Ward.
  239. </para>
  240. </refsect1>
  241. </refentry>