All Projects → tehmaze → django-pam

tehmaze / django-pam

Licence: BSD-2-Clause license
A simple PAM authentication backend for Django

Programming Languages

python
139335 projects - #7 most used programming language

django-pam

A simple PAM authentication backend for Django. Add the folder dpam somewhere on your python path and add 'dpam.backends.PAMBackend' to your settings.py:

AUTHENTICATION_BACKENDS = (
    ...
    'dpam.backends.PAMBackend',
    ...
)

Now you can login via the system-login credentials. If the user is successfully authenticated but has never logged-in before, a new User object is created. By default this new User has both is_staff and is_superuser set to False. You can change this behavior by adding PAM_IS_STAFF=True and PAM_IS_SUPERUSER in your settings.py file.

If you do not want a User record to be created automatically, use PAM_CREATE_USER=False in settings.py. This is useful in situations where you want to use PAM for authentication but not for authorization.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].