From 8d1c76ec7caf247d5675e14260d20fc508977ffb Mon Sep 17 00:00:00 2001 From: Determinant Date: Fri, 23 Aug 2024 03:14:03 +0000 Subject: release v0.1.8 --- frozen_deps/Cryptodome/Cipher/ChaCha20.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'frozen_deps/Cryptodome/Cipher/ChaCha20.py') diff --git a/frozen_deps/Cryptodome/Cipher/ChaCha20.py b/frozen_deps/Cryptodome/Cipher/ChaCha20.py index b4f8b5f..648d692 100644 --- a/frozen_deps/Cryptodome/Cipher/ChaCha20.py +++ b/frozen_deps/Cryptodome/Cipher/ChaCha20.py @@ -106,7 +106,7 @@ class ChaCha20Cipher(object): self._name = "ChaCha20" nonce = self.nonce - self._next = ( self.encrypt, self.decrypt ) + self._next = ("encrypt", "decrypt") self._state = VoidPointer() result = _raw_chacha20_lib.chacha20_init( @@ -134,9 +134,9 @@ class ChaCha20Cipher(object): Otherwise, ``None``. """ - if self.encrypt not in self._next: + if "encrypt" not in self._next: raise TypeError("Cipher object can only be used for decryption") - self._next = ( self.encrypt, ) + self._next = ("encrypt",) return self._encrypt(plaintext, output) def _encrypt(self, plaintext, output): @@ -180,9 +180,9 @@ class ChaCha20Cipher(object): Otherwise, ``None``. """ - if self.decrypt not in self._next: + if "decrypt" not in self._next: raise TypeError("Cipher object can only be used for encryption") - self._next = ( self.decrypt, ) + self._next = ("decrypt",) try: return self._encrypt(ciphertext, output) -- cgit v1.2.3-70-g09d2