eax.hpp
Go to the documentation of this file.
44 template<typename Cipher, typename Padding, std::size_t TagBits, typename MessageAuthenticationCode,
92 template<typename Cipher, typename Padding, std::size_t TagBits, typename MessageAuthenticationCode,
111 inline static block_type begin_message(const cipher_type &cipher, const block_type &plaintext) {
115 inline static block_type process_block(const cipher_type &cipher, const block_type &plaintext) {
144 template<typename Cipher, typename Padding, std::size_t TagBits, typename MessageAuthenticationCode,
149 typedef eax_policy<Cipher, Padding, TagBits, MessageAuthenticationCode, StreamCipher, Allocator>
163 inline static block_type begin_message(const cipher_type &cipher, const block_type &plaintext) {
167 inline static block_type process_block(const cipher_type &cipher, const block_type &plaintext) {
303 template<template<typename, typename, std::size_t, typename, typename, template<typename> class>
Definition: eax.hpp:212
constexpr static const std::size_t block_bits
Definition: eax.hpp:225
block_type process_block(const block_type &plaintext)
Definition: eax.hpp:246
policy_type::associated_data_type associated_data_type
Definition: eax.hpp:222
constexpr static const std::size_t block_words
Definition: eax.hpp:226
policy_type::mac_type mac_type
Definition: eax.hpp:219
policy_type::cipher_type cipher_type
Definition: eax.hpp:216
static std::size_t required_output_size(std::size_t inputlen)
Definition: eax.hpp:254
eax(const key_type &key, const AssociatedDataContainer &associated_data)
Definition: eax.hpp:237
void schedule_associated_data(const AssociatedDataContainer &iad)
Definition: eax.hpp:260
eax(const cipher_type &cipher, const stream_cipher_type &stream_cipher, const mac_type &mac, const AssociatedDataContainer &associated_data)
Definition: eax.hpp:230
block_type end_message(const block_type &plaintext)
Definition: eax.hpp:250
cipher_type::block_type block_type
Definition: eax.hpp:227
cipher_type::key_type key_type
Definition: eax.hpp:221
block_type begin_message(const block_type &plaintext)
Definition: eax.hpp:242
stream_cipher_type stream_cipher
Definition: eax.hpp:267
policy_type::stream_cipher_type stream_cipher_type
Definition: eax.hpp:218
policy_type::padding_type padding_type
Definition: eax.hpp:217
policy_type::nonce_type nonce_type
Definition: eax.hpp:223
Definition: eax.hpp:39
boost::mpl::apply< AccumulatorSet, tag::mac< ProcessingPolicy > >::type::result_type mac(const AccumulatorSet &acc)
Definition: accumulators/mac.hpp:99
boost::mpl::apply< AccumulatorSet, tag::block< Mode > >::type::result_type block(const AccumulatorSet &acc)
Definition: accumulators/block.hpp:259
boost::mpl::apply< AccumulatorSet, tag::stream< Mode > >::type::result_type stream(const AccumulatorSet &acc)
Definition: accumulators/stream.hpp:175
boost::accumulators::accumulator_set< mac::digest< MessageAuthenticationCode::input_block_bits >, boost::accumulators::features< accumulators::tag::mac< MessageAuthenticationCode > >> BlockCipher
Definition: cbc_mac_state.hpp:40
void xor_buf(uint8_t out[], const uint8_t in[], size_t length)
Definition: memory_operations.hpp:245
bool constant_time_compare(const uint8_t x[], const uint8_t y[], size_t len)
Definition: memory_operations.hpp:143
Definition: pair.hpp:31
Definition: cipher.hpp:38
Definition: eax.hpp:148
eax_policy< Cipher, Padding, TagBits, MessageAuthenticationCode, StreamCipher, Allocator > policy_type
Definition: eax.hpp:150
constexpr static const std::size_t block_words
Definition: eax.hpp:160
policy_type::nonce_type nonce_type
Definition: eax.hpp:157
static block_type begin_message(const cipher_type &cipher, const block_type &plaintext)
Definition: eax.hpp:163
policy_type::mac_type mac_type
Definition: eax.hpp:154
static block_type end_message(const cipher_type &cipher, const block_type &plaintext)
Definition: eax.hpp:176
static block_type process_block(const cipher_type &cipher, const block_type &plaintext)
Definition: eax.hpp:167
policy_type::stream_cipher_type stream_cipher_type
Definition: eax.hpp:153
policy_type::padding_type padding_type
Definition: eax.hpp:152
policy_type::associated_data_type associated_data_type
Definition: eax.hpp:156
constexpr static const std::size_t block_bits
Definition: eax.hpp:159
policy_type::block_type block_type
Definition: eax.hpp:161
policy_type::cipher_type cipher_type
Definition: eax.hpp:151
Definition: eax.hpp:96
policy_type::stream_cipher_type stream_cipher_type
Definition: eax.hpp:101
eax_policy< Cipher, Padding, TagBits, MessageAuthenticationCode, StreamCipher, Allocator > policy_type
Definition: eax.hpp:98
policy_type::associated_data_type associated_data_type
Definition: eax.hpp:104
policy_type::padding_type padding_type
Definition: eax.hpp:100
policy_type::nonce_type nonce_type
Definition: eax.hpp:105
policy_type::block_type block_type
Definition: eax.hpp:109
constexpr static const std::size_t block_bits
Definition: eax.hpp:107
constexpr static const std::size_t block_words
Definition: eax.hpp:108
policy_type::cipher_type cipher_type
Definition: eax.hpp:99
policy_type::mac_type mac_type
Definition: eax.hpp:102
static block_type end_message(const cipher_type &cipher, const block_type &plaintext)
Definition: eax.hpp:124
static block_type begin_message(const cipher_type &cipher, const block_type &plaintext)
Definition: eax.hpp:111
static block_type process_block(const cipher_type &cipher, const block_type &plaintext)
Definition: eax.hpp:115
Definition: eax.hpp:46
constexpr static const std::size_t mac_digest_bits
Definition: eax.hpp:53
cipher_type::block_type block_type
Definition: eax.hpp:58
constexpr static const std::size_t block_bits
Definition: eax.hpp:56
std::vector< boost::uint_t< CHAR_BIT >, Allocator< boost::uint_t< CHAR_BIT > > > nonce_type
Definition: eax.hpp:64
constexpr static const std::size_t block_words
Definition: eax.hpp:57
Padding padding_type
Definition: eax.hpp:48
StreamCipher stream_cipher_type
Definition: eax.hpp:49
static void eax_prf(uint8_t tag, size_t block_size, mac_type &mac, const uint8_t in[], size_t length)
Definition: eax.hpp:66
MessageAuthenticationCode mac_type
Definition: eax.hpp:50
std::vector< boost::uint_t< CHAR_BIT >, Allocator< boost::uint_t< CHAR_BIT > > > associated_data_type
Definition: eax.hpp:63
constexpr static const std::size_t tag_bits
Definition: eax.hpp:52
static block_type begin_message(const cipher_type &cipher, const block_type &plaintext)
Definition: eax.hpp:76
BOOST_STATIC_ASSERT(block_bits==128)
BOOST_STATIC_ASSERT(tag_bits >=CHAR_BIT &&tag_bits<=mac_digest_bits)
Definition: eax.hpp:305
detail::eax< Policy< cipher_type, padding_type, TagBits, MessageAuthenticationCode, StreamCipher, Allocator > > type
Definition: eax.hpp:308
Interface for AEAD (Authenticated Encryption with Associated Data) modes. These modes provide both en...
Definition: eax.hpp:288
MessageAuthenticationCode message_authentication_code_type
Definition: eax.hpp:292
detail::eax_decryption_policy< cipher_type, padding_type, TagBits, message_authentication_code_type, stream_cipher_type, Allocator > decryption_policy
Definition: eax.hpp:301
detail::eax_encryption_policy< cipher_type, padding_type, TagBits, message_authentication_code_type, stream_cipher_type, Allocator > encryption_policy
Definition: eax.hpp:297
StreamCipher stream_cipher_type
Definition: eax.hpp:291
Padding< BlockCipher > padding_type
Definition: eax.hpp:290