diff options
Diffstat (limited to 'tests/hazmat')
-rw-r--r-- | tests/hazmat/primitives/test_rsa.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/hazmat/primitives/test_rsa.py b/tests/hazmat/primitives/test_rsa.py index 69fd2933..a5266d57 100644 --- a/tests/hazmat/primitives/test_rsa.py +++ b/tests/hazmat/primitives/test_rsa.py @@ -1249,8 +1249,10 @@ class TestRSADecryption(object): public_exponent=private["public_exponent"], modulus=private["modulus"] ) + ciphertext = binascii.unhexlify(example["encryption"]) + assert len(ciphertext) == math.ceil(skey.key_size / 8.0) message = skey.decrypt( - binascii.unhexlify(example["encryption"]), + ciphertext, padding.PKCS1v15(), backend ) |