Sistema de Apoio ao Processo Legislativo
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

11 lines
415 B

from sapl.hashers import (ZopeSHA1PasswordHasher,
zope_encoded_password_to_django)
def test_zope_encoded_password_to_django():
password = 'saploper'
encoded = '{SSHA}Swzvwt/2lSJfA8KUOl6cRjkpmHLkLkmsKu28'
salt = '5C5JrCrtvA=='
migrated = zope_encoded_password_to_django(encoded)
encoded = ZopeSHA1PasswordHasher().encode(password, salt)
assert migrated == encoded