{
    "mode": "man",
    "parameter": "PAM",
    "section": "7",
    "url": "https://www.chedong.com/phpMan.php/man/PAM/7/json",
    "generated": "2026-06-15T16:01:25Z",
    "sections": {
        "NAME": {
            "content": "PAM, pam - Pluggable Authentication Modules for Linux\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "This manual is intended to offer a quick introduction to Linux-PAM. For more information the\nreader is directed to the Linux-PAM system administrators' guide.\n\nLinux-PAM is a system of libraries that handle the authentication tasks of applications\n(services) on the system. The library provides a stable general interface (Application\nProgramming Interface - API) that privilege granting programs (such as login(1) and su(1))\ndefer to to perform standard authentication tasks.\n\nThe principal feature of the PAM approach is that the nature of the authentication is\ndynamically configurable. In other words, the system administrator is free to choose how\nindividual service-providing applications will authenticate users. This dynamic configuration\nis set by the contents of the single Linux-PAM configuration file /etc/pam.conf.\nAlternatively, the configuration can be set by individual configuration files located in the\n/etc/pam.d/ directory. The presence of this directory will cause Linux-PAM to ignore\n/etc/pam.conf.\n\nVendor-supplied PAM configuration files might be installed in the system directory\n/usr/lib/pam.d/ or a configurable vendor specific directory instead of the machine\nconfiguration directory /etc/pam.d/. If no machine configuration file is found, the\nvendor-supplied file is used. All files in /etc/pam.d/ override files with the same name in\nother directories.\n\nFrom the point of view of the system administrator, for whom this manual is provided, it is\nnot of primary importance to understand the internal behavior of the Linux-PAM library. The\nimportant point to recognize is that the configuration file(s) define the connection between\napplications (services) and the pluggable authentication modules (PAMs) that perform the\nactual authentication tasks.\n\nLinux-PAM separates the tasks of authentication into four independent management groups:\naccount management; authentication management; password management; and session management.\n(We highlight the abbreviations used for these groups in the configuration file.)\n\nSimply put, these groups take care of different aspects of a typical user's request for a\nrestricted service:\n\naccount - provide account verification types of service: has the user's password expired?; is\nthis user permitted access to the requested service?\n\nauthentication - authenticate a user and set up user credentials. Typically this is via some\nchallenge-response request that the user must satisfy: if you are who you claim to be please\nenter your password. Not all authentications are of this type, there exist hardware based\nauthentication schemes (such as the use of smart-cards and biometric devices), with suitable\nmodules, these may be substituted seamlessly for more standard approaches to authentication -\nsuch is the flexibility of Linux-PAM.\n\npassword - this group's responsibility is the task of updating authentication mechanisms.\nTypically, such services are strongly coupled to those of the auth group. Some authentication\nmechanisms lend themselves well to being updated with such a function. Standard UN*X\npassword-based access is the obvious example: please enter a replacement password.\n\nsession - this group of tasks cover things that should be done prior to a service being given\nand after it is withdrawn. Such tasks include the maintenance of audit trails and the\nmounting of the user's home directory. The session management group is important as it\nprovides both an opening and closing hook for modules to affect the services available to a\nuser.\n",
            "subsections": []
        },
        "FILES": {
            "content": "/etc/pam.conf\nthe configuration file\n\n/etc/pam.d\nthe Linux-PAM configuration directory. Generally, if this directory is present, the\n/etc/pam.conf file is ignored.\n\n/usr/lib/pam.d\nthe Linux-PAM vendor configuration directory. Files in /etc/pam.d override files with the\nsame name in this directory.\n\n<vendordir>/pam.d\nthe Linux-PAM vendor configuration directory. Files in /etc/pam.d and /usr/lib/pam.d\noverride files with the same name in this directory. Only available if Linux-PAM was\ncompiled with vendordir enabled.\n",
            "subsections": []
        },
        "ERRORS": {
            "content": "Typically errors generated by the Linux-PAM system of libraries, will be written to\nsyslog(3).\n",
            "subsections": []
        },
        "CONFORMING TO": {
            "content": "DCE-RFC 86.0, October 1995. Contains additional features, but remains backwardly compatible\nwith this RFC.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "pam(3), pamauthenticate(3), pamsmsetcred(3), pamstrerror(3), PAM(7)\n\n\n\nLinux-PAM Manual                             06/08/2020                                       PAM(7)",
            "subsections": []
        }
    },
    "summary": "PAM, pam - Pluggable Authentication Modules for Linux",
    "flags": [],
    "examples": [],
    "see_also": [
        {
            "name": "pam",
            "section": "3",
            "url": "https://www.chedong.com/phpMan.php/man/pam/3/json"
        },
        {
            "name": "pamauthenticate",
            "section": "3",
            "url": "https://www.chedong.com/phpMan.php/man/pamauthenticate/3/json"
        },
        {
            "name": "pamsmsetcred",
            "section": "3",
            "url": "https://www.chedong.com/phpMan.php/man/pamsmsetcred/3/json"
        },
        {
            "name": "pamstrerror",
            "section": "3",
            "url": "https://www.chedong.com/phpMan.php/man/pamstrerror/3/json"
        }
    ]
}