| 1 |
'\" t |
| 2 |
.\" Title: pam_chauthtok |
| 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_CHAUTHTOK" "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_chauthtok \- updating authentication tokens |
| 32 |
.SH "SYNOPSIS" |
| 33 |
.sp |
| 34 |
.ft B |
| 35 |
.nf |
| 36 |
#include <security/pam_appl\&.h> |
| 37 |
.fi |
| 38 |
.ft |
| 39 |
.HP \w'int\ pam_chauthtok('u |
| 40 |
.BI "int pam_chauthtok(pam_handle_t\ *" "pamh" ", int\ " "flags" ");" |
| 41 |
.SH "DESCRIPTION" |
| 42 |
.PP |
| 43 |
The |
| 44 |
\fBpam_chauthtok\fR |
| 45 |
function is used to change the authentication token for a given user (as indicated by the state associated with the handle |
| 46 |
\fIpamh\fR)\&. |
| 47 |
.PP |
| 48 |
The |
| 49 |
\fIpamh\fR |
| 50 |
argument is an authentication handle obtained by a prior call to pam_start()\&. The flags argument is the binary or of zero or more of the following values: |
| 51 |
.PP |
| 52 |
PAM_SILENT |
| 53 |
.RS 4 |
| 54 |
Do not emit any messages\&. |
| 55 |
.RE |
| 56 |
.PP |
| 57 |
PAM_CHANGE_EXPIRED_AUTHTOK |
| 58 |
.RS 4 |
| 59 |
This argument indicates to the modules that the user\*(Aqs authentication token (password) should only be changed if it has expired\&. If this argument is not passed, the application requires that all authentication tokens are to be changed\&. |
| 60 |
.RE |
| 61 |
.SH "RETURN VALUES" |
| 62 |
.PP |
| 63 |
PAM_AUTHTOK_ERR |
| 64 |
.RS 4 |
| 65 |
A module was unable to obtain the new authentication token\&. |
| 66 |
.RE |
| 67 |
.PP |
| 68 |
PAM_AUTHTOK_RECOVERY_ERR |
| 69 |
.RS 4 |
| 70 |
A module was unable to obtain the old authentication token\&. |
| 71 |
.RE |
| 72 |
.PP |
| 73 |
PAM_AUTHTOK_LOCK_BUSY |
| 74 |
.RS 4 |
| 75 |
One or more of the modules was unable to change the authentication token since it is currently locked\&. |
| 76 |
.RE |
| 77 |
.PP |
| 78 |
PAM_AUTHTOK_DISABLE_AGING |
| 79 |
.RS 4 |
| 80 |
Authentication token aging has been disabled for at least one of the modules\&. |
| 81 |
.RE |
| 82 |
.PP |
| 83 |
PAM_PERM_DENIED |
| 84 |
.RS 4 |
| 85 |
Permission denied\&. |
| 86 |
.RE |
| 87 |
.PP |
| 88 |
PAM_SUCCESS |
| 89 |
.RS 4 |
| 90 |
The authentication token was successfully updated\&. |
| 91 |
.RE |
| 92 |
.PP |
| 93 |
PAM_TRY_AGAIN |
| 94 |
.RS 4 |
| 95 |
Not all of the modules were in a position to update the authentication token(s)\&. In such a case none of the user\*(Aqs authentication tokens are updated\&. |
| 96 |
.RE |
| 97 |
.PP |
| 98 |
PAM_USER_UNKNOWN |
| 99 |
.RS 4 |
| 100 |
User unknown to password service\&. |
| 101 |
.RE |
| 102 |
.SH "SEE ALSO" |
| 103 |
.PP |
| 104 |
\fBpam_start\fR(3), |
| 105 |
\fBpam_authenticate\fR(3), |
| 106 |
\fBpam_setcred\fR(3), |
| 107 |
\fBpam_get_item\fR(3), |
| 108 |
\fBpam_strerror\fR(3), |
| 109 |
\fBpam\fR(7) |