pam_set_item(3)pam_set_item(3)NAME
pam_set_item, pam_get_item - authentication information routines for
PAM
SYNOPSIS
[ flag ... ] file ... [ library ... ]
DESCRIPTION
and allow applications and PAM service modules to access and update PAM
information as needed. The information is specified by item_type, and
can be one of the following:
The service name.
The user name.
The user authentication token.
The old user authentication token.
The tty name.
The remote host name.
The remote user name.
The pam_conv structure.
The default prompt used by
The item_type and are available only to the module providers for secu‐
rity reasons. The authentication module, account module, and session
management module should treat as the current authentication token, and
should ignore The password management module should treat as the cur‐
rent authentication token and as the new authentication token.
is passed the authentication handle, pamh, returned by a pointer to the
object, item, and its type, item_type. If successful, copies the item
to an internal storage area allocated by the authentication module and
returns An item that had been previously set will be overwritten by the
new value.
is passed the authentication handle, pamh, returned by an item_type,
and the address of the pointer, item, which is assigned the address of
the requested object. The object data is valid until modified by a
subsequent call to for the same item_type, or unless it is modified by
any of the underlying service modules. If the item has not been previ‐
ously set, returns a NULL pointer. An item retrieved by should not be
modified or freed. The item will be released by
APPLICATION USAGE
Refer to pam(3) for information on thread-safety of PAM interfaces.
RETURN VALUES
Upon success, returns otherwise it returns an error code. Refer to
pam(3) for information on error related return values.
SEE ALSOpam_start(3), pam_authenticate(3), pam_acct_mgmt(3), pam_open_ses‐
sion(3), pam_setcred(3), pam_chauthtok(3), pam_get_user(3), pam(3).
pam_set_item(3)