nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator > Struct Template Reference

#include <chacha20poly1305.hpp>

+ Inheritance diagram for nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >:
+ Collaboration diagram for nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >:

Public Types

typedef policy_type::associated_data_type associated_data_type
 
typedef policy_type::block_type block_type
 
typedef MessageAuthenticationCode mac_type
 
typedef policy_type::nonce_type nonce_type
 
typedef policy_type::padding_type padding_type
 
typedef chacha20poly1305_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator > policy_type
 
typedef std::size_t size_type
 
typedef policy_type::stream_cipher_type stream_cipher_type
 

Public Member Functions

 BOOST_STATIC_ASSERT (nonce_bits==8 *CHAR_BIT||nonce_bits==12 *CHAR_BIT)
 

Static Public Member Functions

static block_type begin_message (const stream_cipher_type &cipher, const block_type &plaintext)
 
static block_type end_message (const stream_cipher_type &cipher, const block_type &plaintext)
 
static block_type process_block (const stream_cipher_type &cipher, const block_type &plaintext)
 

Static Public Attributes

constexpr static const std::size_t block_bits = policy_type::block_bits
 
constexpr static const std::size_t block_words = policy_type::block_words
 
constexpr static const std::size_t nonce_bits = NonceBits
 
constexpr static const std::size_t nonce_size = nonce_bits / CHAR_BIT
 

Member Typedef Documentation

◆ associated_data_type

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
typedef policy_type::associated_data_type nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::associated_data_type

◆ block_type

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
typedef policy_type::block_type nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::block_type

◆ mac_type

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
typedef MessageAuthenticationCode nil::crypto3::stream::modes::detail::chacha20poly1305_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::mac_type
inherited

◆ nonce_type

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
typedef policy_type::nonce_type nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::nonce_type

◆ padding_type

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
typedef policy_type::padding_type nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::padding_type

◆ policy_type

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
typedef chacha20poly1305_policy<Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator> nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::policy_type

◆ size_type

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
typedef std::size_t nil::crypto3::stream::modes::detail::chacha20poly1305_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::size_type
inherited

◆ stream_cipher_type

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
typedef policy_type::stream_cipher_type nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::stream_cipher_type

Member Function Documentation

◆ begin_message()

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
static block_type nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::begin_message ( const stream_cipher_type cipher,
const block_type plaintext 
)
inlinestatic

◆ BOOST_STATIC_ASSERT()

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
nil::crypto3::stream::modes::detail::chacha20poly1305_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::BOOST_STATIC_ASSERT ( nonce_bits  = =8 *CHAR_BIT||nonce_bits==12 *CHAR_BIT)
inherited

◆ end_message()

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
static block_type nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::end_message ( const stream_cipher_type cipher,
const block_type plaintext 
)
inlinestatic

◆ process_block()

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
static block_type nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::process_block ( const stream_cipher_type cipher,
const block_type plaintext 
)
inlinestatic

Member Data Documentation

◆ block_bits

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
constexpr static const std::size_t nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::block_bits = policy_type::block_bits
staticconstexpr

◆ block_words

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
constexpr static const std::size_t nil::crypto3::stream::modes::detail::chacha20poly1305_encryption_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::block_words = policy_type::block_words
staticconstexpr

◆ nonce_bits

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
constexpr static const std::size_t nil::crypto3::stream::modes::detail::chacha20poly1305_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::nonce_bits = NonceBits
staticconstexprinherited

◆ nonce_size

template<typename Padding , std::size_t NonceBits, std::size_t TagBits, typename StreamCipher , typename MessageAuthenticationCode , template< typename > class Allocator>
constexpr static const std::size_t nil::crypto3::stream::modes::detail::chacha20poly1305_policy< Padding, NonceBits, TagBits, StreamCipher, MessageAuthenticationCode, Allocator >::nonce_size = nonce_bits / CHAR_BIT
staticconstexprinherited

The documentation for this struct was generated from the following file: