aboutsummaryrefslogtreecommitdiffstats
path: root/cryptography/hazmat/primitives/cmac.py
diff options
context:
space:
mode:
Diffstat (limited to 'cryptography/hazmat/primitives/cmac.py')
-rw-r--r--cryptography/hazmat/primitives/cmac.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/cryptography/hazmat/primitives/cmac.py b/cryptography/hazmat/primitives/cmac.py
index bbf0bf9c..7e7f65ab 100644
--- a/cryptography/hazmat/primitives/cmac.py
+++ b/cryptography/hazmat/primitives/cmac.py
@@ -36,11 +36,11 @@ class CMAC(object):
raise TypeError(
"Expected instance of interfaces.BlockCipherAlgorithm"
)
- self.algorithm = algorithm
+ self._algorithm = algorithm
self._backend = backend
if ctx is None:
- self._ctx = self._backend.create_cmac_ctx(self.algorithm)
+ self._ctx = self._backend.create_cmac_ctx(self._algorithm)
else:
self._ctx = ctx
@@ -69,7 +69,7 @@ class CMAC(object):
if self._ctx is None:
raise AlreadyFinalized("Context was already finalized")
return CMAC(
- self.algorithm,
+ self._algorithm,
backend=self._backend,
ctx=self._ctx.copy()
)