11#include <botan/block_cipher.h>
12#include <botan/stream_cipher.h>
27 std::string
name()
const override;
29 std::unique_ptr<StreamCipher>
new_object()
const override;
31 void clear()
override;
42 CTR_BE(std::unique_ptr<BlockCipher>
cipher,
size_t ctr_size);
44 void seek(uint64_t offset)
override;
47 void key_schedule(std::span<const uint8_t> key)
override;
48 void cipher_bytes(
const uint8_t in[], uint8_t out[],
size_t length)
override;
49 void generate_keystream(uint8_t out[],
size_t length)
override;
50 void set_iv_bytes(
const uint8_t iv[],
size_t iv_len)
override;
51 void add_counter(uint64_t counter);
53 std::unique_ptr<BlockCipher> m_cipher;
55 const size_t m_block_size;
56 const size_t m_ctr_size;
57 const size_t m_ctr_blocks;
60 std::vector<uint8_t> m_iv;
size_t default_iv_length() const override
bool has_keying_material() const override
size_t buffer_size() const override
Key_Length_Specification key_spec() const override
bool valid_iv_length(size_t iv_len) const override
void seek(uint64_t offset) override
std::unique_ptr< StreamCipher > new_object() const override
std::string name() const override
CTR_BE(std::unique_ptr< BlockCipher > cipher)
void cipher(const uint8_t in[], uint8_t out[], size_t len)
int(* final)(unsigned char *, CTX *)
std::vector< T, secure_allocator< T > > secure_vector