diff options
author | Eli Collins <elic@assurancetechnologies.com> | 2015-07-25 22:32:46 -0400 |
---|---|---|
committer | Eli Collins <elic@assurancetechnologies.com> | 2015-07-25 22:32:46 -0400 |
commit | 467439156221b90af9e7753111f4acc25b15b795 (patch) | |
tree | ba000029cfd223ade74cb910db2fa5615c90b5ae | |
parent | ee075acbf10d1f9dc2ad65e9e04b794a0bec484e (diff) | |
parent | a2440f7d568867916c011a1a7920d7d3e11ab369 (diff) | |
download | passlib-467439156221b90af9e7753111f4acc25b15b795.tar.gz |
Merge from stable
-rw-r--r-- | passlib/tests/test_utils_handlers.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/passlib/tests/test_utils_handlers.py b/passlib/tests/test_utils_handlers.py index cfef921..8546eaf 100644 --- a/passlib/tests/test_utils_handlers.py +++ b/passlib/tests/test_utils_handlers.py @@ -589,10 +589,14 @@ class SkeletonTest(TestCase): {'checksum': 186, 'salt': 132}) # linear rounds + # NOTE: +3 comes from int(math.log(.1,2)), + # where 0.1 = 10% = default allowed variation in rounds + self.patchAttr(hash.sha256_crypt, "default_rounds", 1 << (14 + 3)) self.assertEqual(hash.sha256_crypt.bitsize(), {'checksum': 258, 'rounds': 14, 'salt': 96}) # raw checksum + self.patchAttr(hash.pbkdf2_sha1, "default_rounds", 1 << (13 + 3)) self.assertEqual(hash.pbkdf2_sha1.bitsize(), {'checksum': 160, 'rounds': 13, 'salt': 128}) |