pam_wheel.8.xml 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243
  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="pam_wheel">
  5. <refmeta>
  6. <refentrytitle>pam_wheel</refentrytitle>
  7. <manvolnum>8</manvolnum>
  8. <refmiscinfo class="sectdesc">Linux-PAM Manual</refmiscinfo>
  9. </refmeta>
  10. <refnamediv id="pam_wheel-name">
  11. <refname>pam_wheel</refname>
  12. <refpurpose>Only permit root access to members of group wheel</refpurpose>
  13. </refnamediv>
  14. <refsynopsisdiv>
  15. <cmdsynopsis id="pam_wheel-cmdsynopsis">
  16. <command>pam_wheel.so</command>
  17. <arg choice="opt">
  18. debug
  19. </arg>
  20. <arg choice="opt">
  21. deny
  22. </arg>
  23. <arg choice="opt">
  24. group=<replaceable>name</replaceable>
  25. </arg>
  26. <arg choice="opt">
  27. root_only
  28. </arg>
  29. <arg choice="opt">
  30. trust
  31. </arg>
  32. <arg choice="opt">
  33. use_uid
  34. </arg>
  35. </cmdsynopsis>
  36. </refsynopsisdiv>
  37. <refsect1 id="pam_wheel-description">
  38. <title>DESCRIPTION</title>
  39. <para>
  40. The pam_wheel PAM module is used to enforce the so-called
  41. <emphasis>wheel</emphasis> group. By default it permits
  42. access to the target user if the applicant user is a member of the
  43. <emphasis>wheel</emphasis> group. If no group with this name exist,
  44. the module is using the group with the group-ID
  45. <emphasis remap='B'>0</emphasis>.
  46. </para>
  47. </refsect1>
  48. <refsect1 id="pam_wheel-options">
  49. <title>OPTIONS</title>
  50. <variablelist>
  51. <varlistentry>
  52. <term>
  53. <option>debug</option>
  54. </term>
  55. <listitem>
  56. <para>
  57. Print debug information.
  58. </para>
  59. </listitem>
  60. </varlistentry>
  61. <varlistentry>
  62. <term>
  63. <option>deny</option>
  64. </term>
  65. <listitem>
  66. <para>
  67. Reverse the sense of the auth operation: if the user
  68. is trying to get UID 0 access and is a member of the
  69. wheel group (or the group of the <option>group</option> option),
  70. deny access. Conversely, if the user is not in the group, return
  71. PAM_IGNORE (unless <option>trust</option> was also specified,
  72. in which case we return PAM_SUCCESS).
  73. </para>
  74. </listitem>
  75. </varlistentry>
  76. <varlistentry>
  77. <term>
  78. <option>group=<replaceable>name</replaceable></option>
  79. </term>
  80. <listitem>
  81. <para>
  82. Instead of checking the wheel or GID 0 groups, use
  83. the <option><replaceable>name</replaceable></option> group
  84. to perform the authentication.
  85. </para>
  86. </listitem>
  87. </varlistentry>
  88. <varlistentry>
  89. <term>
  90. <option>root_only</option>
  91. </term>
  92. <listitem>
  93. <para>
  94. The check for wheel membership is done only when the target user
  95. UID is 0.
  96. </para>
  97. </listitem>
  98. </varlistentry>
  99. <varlistentry>
  100. <term>
  101. <option>trust</option>
  102. </term>
  103. <listitem>
  104. <para>
  105. The pam_wheel module will return PAM_SUCCESS instead
  106. of PAM_IGNORE if the user is a member of the wheel group
  107. (thus with a little play stacking the modules the wheel
  108. members may be able to su to root without being prompted
  109. for a passwd).
  110. </para>
  111. </listitem>
  112. </varlistentry>
  113. <varlistentry>
  114. <term>
  115. <option>use_uid</option>
  116. </term>
  117. <listitem>
  118. <para>
  119. The check will be done against the real uid of the calling process,
  120. instead of trying to obtain the user from the login session
  121. associated with the terminal in use.
  122. </para>
  123. </listitem>
  124. </varlistentry>
  125. </variablelist>
  126. </refsect1>
  127. <refsect1 id="pam_wheel-types">
  128. <title>MODULE TYPES PROVIDED</title>
  129. <para>
  130. The <emphasis remap='B'>auth</emphasis> and
  131. <emphasis remap='B'>account</emphasis> module types are provided.
  132. </para>
  133. </refsect1>
  134. <refsect1 id='pam_wheel-return_values'>
  135. <title>RETURN VALUES</title>
  136. <variablelist>
  137. <varlistentry>
  138. <term>PAM_AUTH_ERR</term>
  139. <listitem>
  140. <para>
  141. Authentication failure.
  142. </para>
  143. </listitem>
  144. </varlistentry>
  145. <varlistentry>
  146. <term>PAM_BUF_ERR</term>
  147. <listitem>
  148. <para>
  149. Memory buffer error.
  150. </para>
  151. </listitem>
  152. </varlistentry>
  153. <varlistentry>
  154. <term>PAM_IGNORE</term>
  155. <listitem>
  156. <para>
  157. The return value should be ignored by PAM dispatch.
  158. </para>
  159. </listitem>
  160. </varlistentry>
  161. <varlistentry>
  162. <term>PAM_PERM_DENY</term>
  163. <listitem>
  164. <para>
  165. Permission denied.
  166. </para>
  167. </listitem>
  168. </varlistentry>
  169. <varlistentry>
  170. <term>PAM_SERVICE_ERR</term>
  171. <listitem>
  172. <para>
  173. Cannot determine the user name.
  174. </para>
  175. </listitem>
  176. </varlistentry>
  177. <varlistentry>
  178. <term>PAM_SUCCESS</term>
  179. <listitem>
  180. <para>
  181. Success.
  182. </para>
  183. </listitem>
  184. </varlistentry>
  185. <varlistentry>
  186. <term>PAM_USER_UNKNOWN</term>
  187. <listitem>
  188. <para>
  189. User not known.
  190. </para>
  191. </listitem>
  192. </varlistentry>
  193. </variablelist>
  194. </refsect1>
  195. <refsect1 id='pam_wheel-examples'>
  196. <title>EXAMPLES</title>
  197. <para>
  198. The root account gains access by default (rootok), only wheel
  199. members can become root (wheel) but Unix authenticate non-root
  200. applicants.
  201. <programlisting>
  202. su auth sufficient pam_rootok.so
  203. su auth required pam_wheel.so
  204. su auth required pam_unix.so
  205. </programlisting>
  206. </para>
  207. </refsect1>
  208. <refsect1 id='pam_wheel-see_also'>
  209. <title>SEE ALSO</title>
  210. <para>
  211. <citerefentry>
  212. <refentrytitle>pam.conf</refentrytitle><manvolnum>5</manvolnum>
  213. </citerefentry>,
  214. <citerefentry>
  215. <refentrytitle>pam.d</refentrytitle><manvolnum>5</manvolnum>
  216. </citerefentry>,
  217. <citerefentry>
  218. <refentrytitle>pam</refentrytitle><manvolnum>8</manvolnum>
  219. </citerefentry>
  220. </para>
  221. </refsect1>
  222. <refsect1 id='pam_wheel-author'>
  223. <title>AUTHOR</title>
  224. <para>
  225. pam_wheel was written by Cristian Gafton &lt;gafton@redhat.com&gt;.
  226. </para>
  227. </refsect1>
  228. </refentry>