| 1 |
'\" t |
| 2 |
.\" Title: pam_sm_authenticate |
| 3 |
.\" Author: [FIXME: author] [see http://www.docbook.org/tdg5/en/html/author] |
| 4 |
.\" Generator: DocBook XSL Stylesheets v1.79.2 <http://docbook.sf.net/> |
| 5 |
.\" Date: 06/29/2025 |
| 6 |
.\" Manual: Linux-PAM Manual |
| 7 |
.\" Source: Linux-PAM |
| 8 |
.\" Language: English |
| 9 |
.\" |
| 10 |
.TH "PAM_SM_AUTHENTICATE" "3" "06/29/2025" "Linux\-PAM" "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_sm_authenticate \- PAM service function for user authentication |
| 32 |
.SH "SYNOPSIS" |
| 33 |
.sp |
| 34 |
.ft B |
| 35 |
.nf |
| 36 |
#include <security/pam_modules\&.h> |
| 37 |
.fi |
| 38 |
.ft |
| 39 |
.HP \w'int\ pam_sm_authenticate('u |
| 40 |
.BI "int pam_sm_authenticate(pam_handle_t\ *" "pamh" ", int\ " "flags" ", int\ " "argc" ", const\ char\ **" "argv" ");" |
| 41 |
.SH "DESCRIPTION" |
| 42 |
.PP |
| 43 |
The |
| 44 |
\fBpam_sm_authenticate\fR |
| 45 |
function is the service module\*(Aqs implementation of the |
| 46 |
\fBpam_authenticate\fR(3) |
| 47 |
interface\&. |
| 48 |
.PP |
| 49 |
This function performs the task of authenticating the user\&. |
| 50 |
.PP |
| 51 |
Valid flags, which may be logically OR\*(Aqd with |
| 52 |
\fIPAM_SILENT\fR, are: |
| 53 |
.PP |
| 54 |
PAM_SILENT |
| 55 |
.RS 4 |
| 56 |
Do not emit any messages\&. |
| 57 |
.RE |
| 58 |
.PP |
| 59 |
PAM_DISALLOW_NULL_AUTHTOK |
| 60 |
.RS 4 |
| 61 |
Return |
| 62 |
\fBPAM_AUTH_ERR\fR |
| 63 |
if the database of authentication tokens for this authentication mechanism has a |
| 64 |
\fINULL\fR |
| 65 |
entry for the user\&. Without this flag, such a |
| 66 |
\fINULL\fR |
| 67 |
token will lead to a success without the user being prompted\&. |
| 68 |
.RE |
| 69 |
.SH "RETURN VALUES" |
| 70 |
.PP |
| 71 |
PAM_AUTH_ERR |
| 72 |
.RS 4 |
| 73 |
Authentication failure\&. |
| 74 |
.RE |
| 75 |
.PP |
| 76 |
PAM_CRED_INSUFFICIENT |
| 77 |
.RS 4 |
| 78 |
For some reason the application does not have sufficient credentials to authenticate the user\&. |
| 79 |
.RE |
| 80 |
.PP |
| 81 |
PAM_AUTHINFO_UNAVAIL |
| 82 |
.RS 4 |
| 83 |
The modules were not able to access the authentication information\&. This might be due to a network or hardware failure etc\&. |
| 84 |
.RE |
| 85 |
.PP |
| 86 |
PAM_SUCCESS |
| 87 |
.RS 4 |
| 88 |
The authentication token was successfully updated\&. |
| 89 |
.RE |
| 90 |
.PP |
| 91 |
PAM_USER_UNKNOWN |
| 92 |
.RS 4 |
| 93 |
The supplied username is not known to the authentication service\&. |
| 94 |
.RE |
| 95 |
.PP |
| 96 |
PAM_MAXTRIES |
| 97 |
.RS 4 |
| 98 |
One or more of the authentication modules has reached its limit of tries authenticating the user\&. Do not try again\&. |
| 99 |
.RE |
| 100 |
.SH "SEE ALSO" |
| 101 |
.PP |
| 102 |
\fBpam\fR(3), |
| 103 |
\fBpam_authenticate\fR(3), |
| 104 |
\fBpam_sm_setcred\fR(3), |
| 105 |
\fBpam_strerror\fR(3), |
| 106 |
\fBPAM\fR(8) |