Django app for forcing password expiration
Project description
Django password expiration app
This app provides configurable expiration of passwords.
Features
- Configurable password duration and warning duration
- Visual warning to user using Django messages
- Prevents user from logging in after expiration
Installation
pip install django-password-expire
.- Add
password_expire
toINSTALLED_APPS
. - Add
'password_expire.middleware.PasswordExpireMiddleware'
toMIDDLEWARE
. It should be listed after authentication and session middlewares. - Configure the app in your settings:
# contact information if password is expired PASSWORD_EXPIRE_CONTACT = "John Doe <jdoe@example.com>" # expire passwords after 90 days PASSWORD_EXPIRE_SECONDS = 90 * 24 * 60 * 60 # start warning 10 days before expiration PASSWORD_EXPIRE_WARN_SECONDS = 10 * 24 * 60 * 60
- Run
python manage.py migrate
to create the required database tables.
To redirect new users to the change password page, set this flag in the settings:
PASSWORD_EXPIRE_FORCE = True
Acknowledgements
This app is inspired by django-password-policies-iplweb.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for django-password-expire-0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | e0b68de44ef7090b4a754cf0aaaca9085d7fada18b7a981b2276543c787d6efc |
|
MD5 | 1417384cb9ff8d6b1581984633b3ec68 |
|
BLAKE2b-256 | 289426b508e1e0bd4c6936d6be319401aeea72592a9dc0038a73a442e138a758 |
Close
Hashes for django_password_expire-0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 21df9f5705c827a0894a143e9d5d96ab3a498df39a7ef8f19b616961b6964868 |
|
MD5 | 190161aeecf59360e9026c6da330836a |
|
BLAKE2b-256 | 202f600b1cfb7f1ad3a404e4187a059d143ef3b07a41c56156025886bc1d3a2c |