PAM.8 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. '\" t
  2. .\" Title: pam
  3. .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author]
  4. .\" Generator: DocBook XSL Stylesheets v1.79.1 <http://docbook.sf.net/>
  5. .\" Date: 09/03/2021
  6. .\" Manual: Linux-PAM Manual
  7. .\" Source: Linux-PAM Manual
  8. .\" Language: English
  9. .\"
  10. .TH "PAM" "8" "09/03/2021" "Linux-PAM Manual" "Linux-PAM Manual"
  11. .\" -----------------------------------------------------------------
  12. .\" * Define some portability stuff
  13. .\" -----------------------------------------------------------------
  14. .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  15. .\" http://bugs.debian.org/507673
  16. .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
  17. .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  18. .ie \n(.g .ds Aq \(aq
  19. .el .ds Aq '
  20. .\" -----------------------------------------------------------------
  21. .\" * set default formatting
  22. .\" -----------------------------------------------------------------
  23. .\" disable hyphenation
  24. .nh
  25. .\" disable justification (adjust text to left margin only)
  26. .ad l
  27. .\" -----------------------------------------------------------------
  28. .\" * MAIN CONTENT STARTS HERE *
  29. .\" -----------------------------------------------------------------
  30. .SH "NAME"
  31. PAM, pam \- Pluggable Authentication Modules for Linux
  32. .SH "DESCRIPTION"
  33. .PP
  34. This manual is intended to offer a quick introduction to
  35. \fBLinux\-PAM\fR\&. For more information the reader is directed to the
  36. \fBLinux\-PAM system administrators\*(Aq guide\fR\&.
  37. .PP
  38. \fBLinux\-PAM\fR
  39. is a system of libraries that handle the authentication tasks of applications (services) on the system\&. The library provides a stable general interface (Application Programming Interface \- API) that privilege granting programs (such as
  40. \fBlogin\fR(1)
  41. and
  42. \fBsu\fR(1)) defer to to perform standard authentication tasks\&.
  43. .PP
  44. The principal feature of the PAM approach is that the nature of the authentication is dynamically configurable\&. In other words, the system administrator is free to choose how individual service\-providing applications will authenticate users\&. This dynamic configuration is set by the contents of the single
  45. \fBLinux\-PAM\fR
  46. configuration file
  47. /etc/pam\&.conf\&. Alternatively, the configuration can be set by individual configuration files located in the
  48. /etc/pam\&.d/
  49. directory\&. The presence of this directory will cause
  50. \fBLinux\-PAM\fR
  51. to
  52. \fIignore\fR
  53. /etc/pam\&.conf\&.
  54. .PP
  55. Vendor\-supplied PAM configuration files might be installed in the system directory
  56. /usr/lib/pam\&.d/
  57. or a configurable vendor specific directory instead of the machine configuration directory
  58. /etc/pam\&.d/\&. If no machine configuration file is found, the vendor\-supplied file is used\&. All files in
  59. /etc/pam\&.d/
  60. override files with the same name in other directories\&.
  61. .PP
  62. From the point of view of the system administrator, for whom this manual is provided, it is not of primary importance to understand the internal behavior of the
  63. \fBLinux\-PAM\fR
  64. library\&. The important point to recognize is that the configuration file(s)
  65. \fIdefine\fR
  66. the connection between applications
  67. (\fBservices\fR) and the pluggable authentication modules
  68. (\fBPAM\fRs) that perform the actual authentication tasks\&.
  69. .PP
  70. \fBLinux\-PAM\fR
  71. separates the tasks of
  72. \fIauthentication\fR
  73. into four independent management groups:
  74. \fBaccount\fR
  75. management;
  76. \fBauth\fRentication management;
  77. \fBpassword\fR
  78. management; and
  79. \fBsession\fR
  80. management\&. (We highlight the abbreviations used for these groups in the configuration file\&.)
  81. .PP
  82. Simply put, these groups take care of different aspects of a typical user\*(Aqs request for a restricted service:
  83. .PP
  84. \fBaccount\fR
  85. \- provide account verification types of service: has the user\*(Aqs password expired?; is this user permitted access to the requested service?
  86. .PP
  87. \fBauth\fRentication \- authenticate a user and set up user credentials\&. Typically this is via some challenge\-response request that the user must satisfy: if you are who you claim to be please enter your password\&. Not all authentications are of this type, there exist hardware based authentication schemes (such as the use of smart\-cards and biometric devices), with suitable modules, these may be substituted seamlessly for more standard approaches to authentication \- such is the flexibility of
  88. \fBLinux\-PAM\fR\&.
  89. .PP
  90. \fBpassword\fR
  91. \- this group\*(Aqs responsibility is the task of updating authentication mechanisms\&. Typically, such services are strongly coupled to those of the
  92. \fBauth\fR
  93. group\&. Some authentication mechanisms lend themselves well to being updated with such a function\&. Standard UN*X password\-based access is the obvious example: please enter a replacement password\&.
  94. .PP
  95. \fBsession\fR
  96. \- this group of tasks cover things that should be done prior to a service being given and after it is withdrawn\&. Such tasks include the maintenance of audit trails and the mounting of the user\*(Aqs home directory\&. The
  97. \fBsession\fR
  98. management group is important as it provides both an opening and closing hook for modules to affect the services available to a user\&.
  99. .SH "FILES"
  100. .PP
  101. /etc/pam\&.conf
  102. .RS 4
  103. the configuration file
  104. .RE
  105. .PP
  106. /etc/pam\&.d
  107. .RS 4
  108. the
  109. \fBLinux\-PAM\fR
  110. configuration directory\&. Generally, if this directory is present, the
  111. /etc/pam\&.conf
  112. file is ignored\&.
  113. .RE
  114. .PP
  115. /usr/lib/pam\&.d
  116. .RS 4
  117. the
  118. \fBLinux\-PAM\fR
  119. vendor configuration directory\&. Files in
  120. /etc/pam\&.d
  121. override files with the same name in this directory\&.
  122. .RE
  123. .PP
  124. <vendordir>/pam\&.d
  125. .RS 4
  126. the
  127. \fBLinux\-PAM\fR
  128. vendor configuration directory\&. Files in
  129. /etc/pam\&.d
  130. and
  131. /usr/lib/pam\&.d
  132. override files with the same name in this directory\&. Only available if Linux\-PAM was compiled with vendordir enabled\&.
  133. .RE
  134. .SH "ERRORS"
  135. .PP
  136. Typically errors generated by the
  137. \fBLinux\-PAM\fR
  138. system of libraries, will be written to
  139. \fBsyslog\fR(3)\&.
  140. .SH "CONFORMING TO"
  141. .PP
  142. DCE\-RFC 86\&.0, October 1995\&. Contains additional features, but remains backwardly compatible with this RFC\&.
  143. .SH "SEE ALSO"
  144. .PP
  145. \fBpam\fR(3),
  146. \fBpam_authenticate\fR(3),
  147. \fBpam_sm_setcred\fR(3),
  148. \fBpam_strerror\fR(3),
  149. \fBPAM\fR(8)