23 #ifndef CRYPTO_AUTHENTICATEDCIPHER_h
24 #define CRYPTO_AUTHENTICATEDCIPHER_h
39 virtual bool checkTag(
const void *tag,
size_t len) = 0;
Abstract base class for authenticated ciphers.
AuthenticatedCipher()
Constructs a new authenticated cipher.
virtual bool checkTag(const void *tag, size_t len)=0
Finalizes the decryption process and checks the authentication tag.
virtual size_t tagSize() const =0
Returns the size of the authentication tag.
virtual void computeTag(void *tag, size_t len)=0
Finalizes the encryption process and computes the authentication tag.
virtual void addAuthData(const void *data, size_t len)=0
Adds extra data that will be authenticated but not encrypted.
virtual ~AuthenticatedCipher()
Destroys this authenticated cipher.
Abstract base class for stream ciphers.