|
Botan 3.13.0
Crypto and TLS for C&
|
#include <sym_algo.h>
Public Member Functions | |
| Key_Length_Specification (size_t keylen) | |
| Key_Length_Specification (size_t min_k, size_t max_k, size_t k_mod=1) | |
| size_t | keylength_multiple () const |
| size_t | maximum_keylength () const |
| size_t | minimum_keylength () const |
| Key_Length_Specification | multiple (size_t n) const |
| bool | valid_keylength (size_t length) const |
Represents the length requirements on an algorithm key
Definition at line 22 of file sym_algo.h.
|
inlineexplicit |
Constructor for fixed length keys
| keylen | the supported key length |
Definition at line 28 of file sym_algo.h.
Referenced by multiple().
|
inline |
Constructor for variable length keys
| min_k | the smallest supported key length |
| max_k | the largest supported key length |
| k_mod | the number of bytes the key must be a multiple of |
Definition at line 36 of file sym_algo.h.
|
inline |
Return the granularity of acceptable key lengths
Definition at line 64 of file sym_algo.h.
|
inline |
Return the largest acceptable key length
Definition at line 58 of file sym_algo.h.
|
inline |
Return the smallest acceptable key length
Definition at line 52 of file sym_algo.h.
|
inline |
Scale all length requirements by a factor Multiplies all length requirements with the given factor
| n | the multiplication factor |
Definition at line 72 of file sym_algo.h.
References Key_Length_Specification().
Referenced by Botan::SIV_Mode::key_spec(), and Botan::XTS_Mode::key_spec().
|
inline |
Test if a key length is acceptable
| length | is a key length in bytes |
Definition at line 44 of file sym_algo.h.