Expand description
Rustified API to the Linux-PAM authentication libary
This library supports both PAM clients and modules through the respective
cargo features. If you do not want to use any high-level API, wrappers
for the raw PAM related functions from pam_sys
are also exported at crate
root.
Re-exports§
Modules§
- client
- Authentication related structure and functions
Structs§
- PamError
- PAM related error with
PamReturnCode
inside it - Password
Conv - A minimalistic conversation handler, that uses given login and password
Enums§
- PamFlag
- The Linux-PAM flags
- PamItem
Type - The Linux-PAM item types
- PamMessage
Style - The Linux-PAM message styles
- PamReturn
Code - The Linux-PAM return values
Traits§
- Conversation
- A trait representing the PAM authentification conversation
Functions§
- acct_
mgmt - Determine if the user’s account is valid
- authenticate
- Authenticate the user via the
Conversation
passed tostart
- chauthtok
- Change the authentication token for the user associated with the PAM transaction
- close_
session - Indicate that an authenticated user session has ended
- end
- Terminate the PAM transaction
- get_
item - Retrieve PAM information of type
item_type
from the associated PAM transaction - getenv
- Get he value of a PAM environment variable associated with the PAM transaction
- getenvlist
- Retrieve a complee copy of the PAM environment associated with the PAM transaction
- misc_
paste_ env - Update the PAM environment via the supplied list
- misc_
setenv - Add or change PAM environment variables associated with the PAM transaction in BSD style “name=value”
- open_
session - Set up a user session for a previously authenticated user
- putenv
- Add or change PAM environment variables associated with the PAM transaction
- set_
item - Update PAM information of type
item_type
in the associated PAM transaction - setcred
- Modify the credentials of the user associated with the PAM transaction
- start
- Create the PAM context and initiate the PAM transaction
- strerror
- Retrieve a
CStr
describing thePamReturnCode
passed, potentially using LC_MESSAGES to localize the result
Type Aliases§
- PamHandle
- Opaque PAM main structure. Used for nearly all application functions
- PamMessage
- PAM message that is passed to modules
- PamResponse
- PAM response returned by modules
- PamResult
- Convenience type for functions that might fail with a
PamError