aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/cryptography/hazmat/primitives/interfaces/__init__.py11
-rw-r--r--src/cryptography/hazmat/primitives/interfaces/ciphers.py9
2 files changed, 11 insertions, 9 deletions
diff --git a/src/cryptography/hazmat/primitives/interfaces/__init__.py b/src/cryptography/hazmat/primitives/interfaces/__init__.py
index 6dedd1f8..2f9880da 100644
--- a/src/cryptography/hazmat/primitives/interfaces/__init__.py
+++ b/src/cryptography/hazmat/primitives/interfaces/__init__.py
@@ -12,6 +12,7 @@ from cryptography.hazmat.primitives.interfaces.ciphers import (
BlockCipherAlgorithm,
CipherAlgorithm,
Mode,
+ ModeWithAuthenticationTag,
ModeWithInitializationVector,
ModeWithNonce)
@@ -19,21 +20,13 @@ __all__ = [
"BlockCipherAlgorithm",
"CipherAlgorithm",
"Mode",
+ "ModeWithAuthenticationTag",
"ModeWithInitializationVector",
"ModeWithNonce"
]
@six.add_metaclass(abc.ABCMeta)
-class ModeWithAuthenticationTag(object):
- @abc.abstractproperty
- def tag(self):
- """
- The value of the tag supplied to the constructor of this mode.
- """
-
-
-@six.add_metaclass(abc.ABCMeta)
class CipherContext(object):
@abc.abstractmethod
def update(self, data):
diff --git a/src/cryptography/hazmat/primitives/interfaces/ciphers.py b/src/cryptography/hazmat/primitives/interfaces/ciphers.py
index df6d5f74..075a9c25 100644
--- a/src/cryptography/hazmat/primitives/interfaces/ciphers.py
+++ b/src/cryptography/hazmat/primitives/interfaces/ciphers.py
@@ -65,3 +65,12 @@ class ModeWithNonce(object):
"""
The value of the nonce for this mode as bytes.
"""
+
+
+@six.add_metaclass(abc.ABCMeta)
+class ModeWithAuthenticationTag(object):
+ @abc.abstractproperty
+ def tag(self):
+ """
+ The value of the tag supplied to the constructor of this mode.
+ """