Created
January 15, 2015 00:39
-
-
Save hgdeoro/1b27610736bd64c35535 to your computer and use it in GitHub Desktop.
Custom hasher, hereda de PBKDF2PasswordHasher y utiliza valor de "iterations" de Django 1.7.2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MyPBKDF2PasswordHasher(PBKDF2PasswordHasher): | |
iterations = 12000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PASSWORD_HASHERS = ( | |
'my.package.custom_hasher.MyPBKDF2PasswordHasher', | |
'django.contrib.auth.hashers.PBKDF2PasswordHasher', | |
'django.contrib.auth.hashers.PBKDF2SHA1PasswordHasher', | |
'django.contrib.auth.hashers.BCryptSHA256PasswordHasher', | |
'django.contrib.auth.hashers.BCryptPasswordHasher', | |
'django.contrib.auth.hashers.SHA1PasswordHasher', | |
'django.contrib.auth.hashers.MD5PasswordHasher', | |
'django.contrib.auth.hashers.CryptPasswordHasher', | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment