diff options
Diffstat (limited to 'src/aead/eax/eax.h')
-rw-r--r-- | src/aead/eax/eax.h | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/aead/eax/eax.h b/src/aead/eax/eax.h index f7e1c6387..f3562f755 100644 --- a/src/aead/eax/eax.h +++ b/src/aead/eax/eax.h @@ -9,7 +9,6 @@ #define BOTAN_EAX_H__ #include <botan/aead.h> -#include <botan/buf_filt.h> #include <botan/block_cipher.h> #include <botan/stream_cipher.h> #include <botan/mac.h> @@ -18,23 +17,25 @@ namespace Botan { /** -* EAX Mode +* EAX base class */ class BOTAN_DLL EAX_Mode : public AEAD_Mode { public: - size_t update_granularity() const; - secure_vector<byte> start(const byte nonce[], size_t nonce_len) override; void set_associated_data(const byte ad[], size_t ad_len) override; std::string name() const override; - Key_Length_Specification key_spec() const override { return m_cipher->key_spec(); } + size_t update_granularity() const; + + Key_Length_Specification key_spec() const override; // EAX supports arbitrary nonce lengths bool valid_nonce_length(size_t) const override { return true; } + + void clear(); protected: void key_schedule(const byte key[], size_t length) override; @@ -72,6 +73,8 @@ class BOTAN_DLL EAX_Encryption : public EAX_Mode EAX_Encryption(BlockCipher* cipher, size_t tag_size = 16) : EAX_Mode(cipher, tag_size) {} + size_t minimum_final_size() const override { return 0; } + void update(secure_vector<byte>& blocks) override; void finish(secure_vector<byte>& final_block) override; |