Pluggable Authentication Modules (PAM) provides a system of libraries that handle the authentication tasks of applications (services) on a Linux system. These libraries are loaded dynamically and can be configured in the /etc/pam.d directory or in /etc/pam.conf. The PAM modules are divided into four types: auth (authentication): This module type is responsible for authenticating the user, setting up user credentials, and initiating a session. account: This module type manages account policies such as password expiration, access restrictions, and checking user permissions. password: This module type handles the updating of authentication tokens, such as passwords. session: This module type manages tasks that need to be performed at the beginning and end of a session, like mounting directories or logging. Reference: Linux PAM Documentation Understanding PAM