diff options
Diffstat (limited to 'cryptography/hazmat/bindings/openssl/backend.py')
-rw-r--r-- | cryptography/hazmat/bindings/openssl/backend.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/cryptography/hazmat/bindings/openssl/backend.py b/cryptography/hazmat/bindings/openssl/backend.py index 8de37d5b..f9bef1a5 100644 --- a/cryptography/hazmat/bindings/openssl/backend.py +++ b/cryptography/hazmat/bindings/openssl/backend.py @@ -20,7 +20,7 @@ import cffi from cryptography.hazmat.primitives import interfaces from cryptography.hazmat.primitives.block.ciphers import ( - AES, Camellia, TripleDES, + AES, Blowfish, Camellia, TripleDES, ) from cryptography.hazmat.primitives.block.modes import CBC, CTR, ECB, OFB, CFB @@ -221,6 +221,12 @@ class Ciphers(object): mode_cls, GetCipherByName("des-ede3-{mode.name}") ) + for mode_cls in [CBC, CFB, OFB, ECB]: + self.register_cipher_adapter( + Blowfish, + mode_cls, + GetCipherByName("bf-{mode.name}") + ) def create_encrypt_ctx(self, cipher, mode): return _CipherContext(self._backend, cipher, mode, |