##// END OF EJS Templates
Allow unicode arguments to passwd_check on Python 2....
Thomas Kluyver -
Show More
@@ -113,6 +113,6 b' def passwd_check(hashed_passphrase, passphrase):'
113 if len(pw_digest) == 0:
113 if len(pw_digest) == 0:
114 return False
114 return False
115
115
116 h.update(cast_bytes(passphrase, 'utf-8') + str_to_bytes(salt, 'ascii'))
116 h.update(cast_bytes(passphrase, 'utf-8') + cast_bytes(salt, 'ascii'))
117
117
118 return h.hexdigest() == pw_digest
118 return h.hexdigest() == pw_digest
General Comments 0
You need to be logged in to leave comments. Login now