{
    "mode": "man",
    "parameter": "PAM_LOCALUSER",
    "section": "8",
    "url": "https://www.chedong.com/phpMan.php/man/PAM_LOCALUSER/8/json",
    "generated": "2026-10-10T12:58:40Z",
    "synopsis": "pamlocaluser.so [debug] [file=/path/passwd]",
    "sections": {
        "NAME": {
            "content": "pamlocaluser - require users to be listed in /etc/passwd\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "pamlocaluser.so [debug] [file=/path/passwd]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "pamlocaluser is a PAM module to help implementing site-wide login policies, where they\ntypically include a subset of the network's users and a few accounts that are local to a\nparticular workstation. Using pamlocaluser and pamwheel or pamlistfile is an effective way\nto restrict access to either local users and/or a subset of the network's users.\n\nThis could also be implemented using pamlistfile.so and a very short awk script invoked by\ncron, but it's common enough to have been separated out.\n",
            "subsections": []
        },
        "OPTIONS": {
            "content": "debug\nPrint debug information.\n\nfile=/path/passwd\nUse a file other than /etc/passwd.\n",
            "subsections": []
        },
        "MODULE TYPES PROVIDED": {
            "content": "All module types (account, auth, password and session) are provided.\n",
            "subsections": []
        },
        "RETURN VALUES": {
            "content": "PAMSUCCESS\nThe new localuser was set successfully.\n\nPAMBUFERR\nMemory buffer error.\n\nPAMCONVERR\nThe conversation method supplied by the application failed to obtain the username.\n\nPAMINCOMPLETE\nThe conversation method supplied by the application returned PAMCONVAGAIN.\n\nPAMSERVICEERR\nThe user name is not valid or the passwd file is unavailable.\n\nPAMPERMDENIED\nThe user is not listed in the passwd file.\n",
            "subsections": []
        },
        "EXAMPLES": {
            "content": "Add the following lines to /etc/pam.d/su to allow only local users or group wheel to use su.\n\naccount sufficient pamlocaluser.so\naccount required pamwheel.so\n\n\n",
            "subsections": []
        },
        "FILES": {
            "content": "/etc/passwd\nLocal user account information.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "pam.conf(5), pam.d(5), pam(7)\n",
            "subsections": []
        },
        "AUTHOR": {
            "content": "pamlocaluser was written by Nalin Dahyabhai <nalin@redhat.com>.\n\nLinux-PAM                                    05/07/2023                             PAMLOCALUSER(8)",
            "subsections": []
        }
    },
    "summary": "pamlocaluser - require users to be listed in /etc/passwd",
    "flags": [],
    "examples": [
        "Add the following lines to /etc/pam.d/su to allow only local users or group wheel to use su.",
        "account sufficient pamlocaluser.so",
        "account required pamwheel.so"
    ],
    "see_also": [
        {
            "name": "pam.conf",
            "section": "5",
            "url": "https://www.chedong.com/phpMan.php/man/pam.conf/5/json"
        },
        {
            "name": "pam.d",
            "section": "5",
            "url": "https://www.chedong.com/phpMan.php/man/pam.d/5/json"
        },
        {
            "name": "pam",
            "section": "7",
            "url": "https://www.chedong.com/phpMan.php/man/pam/7/json"
        }
    ]
}