Botan 3.0.0-alpha0
Crypto and TLS for C&
|
Namespaces | |
namespace | ARIA_F |
namespace | ASN1 |
namespace | Camellia_F |
namespace | Cert_Extension |
namespace | CryptoBox |
namespace | CT |
namespace | FPE |
namespace | HTTP |
namespace | KeyPair |
namespace | OCSP |
namespace | OIDS |
namespace | OS |
namespace | PEM_Code |
namespace | PK_Ops |
namespace | PKCS11 |
namespace | PKCS8 |
namespace | PKIX |
namespace | Roughtime |
namespace | Serpent_F |
namespace | SHA1_F |
namespace | SHA1_SSE2_F |
namespace | Sodium |
namespace | Threefish_F |
namespace | TLS |
namespace | X509 |
Functions | |
BigInt | abs (const BigInt &n) |
BOTAN_MALLOC_FN void * | allocate_memory (size_t elems, size_t elem_size) |
void | argon2 (uint8_t output[], size_t output_len, const char *password, size_t password_len, const uint8_t salt[], size_t salt_len, const uint8_t key[], size_t key_len, const uint8_t ad[], size_t ad_len, uint8_t y, size_t p, size_t M, size_t t) |
bool | argon2_check_pwhash (const char *password, size_t password_len, const std::string &input_hash) |
std::string | argon2_generate_pwhash (const char *password, size_t password_len, RandomNumberGenerator &rng, size_t p, size_t M, size_t t, uint8_t y, size_t salt_len, size_t output_len) |
std::string | asn1_class_to_string (ASN1_Class type) |
std::string | asn1_tag_to_string (ASN1_Type type) |
void | assertion_failure (const char *expr_str, const char *assertion_made, const char *func, const char *file, int line) |
secure_vector< uint8_t > | base32_decode (const char input[], size_t input_length, bool ignore_ws) |
secure_vector< uint8_t > | base32_decode (const std::string &input, bool ignore_ws) |
size_t | base32_decode (uint8_t out[], const char in[], size_t input_length, size_t &input_consumed, bool final_inputs, bool ignore_ws) |
size_t | base32_decode (uint8_t output[], const char input[], size_t input_length, bool ignore_ws) |
size_t | base32_decode (uint8_t output[], const std::string &input, bool ignore_ws) |
size_t | base32_encode (char out[], const uint8_t in[], size_t input_length, size_t &input_consumed, bool final_inputs) |
template<typename Alloc > | |
std::string | base32_encode (const std::vector< uint8_t, Alloc > &input) |
std::string | base32_encode (const uint8_t input[], size_t input_length) |
std::vector< uint8_t > | base58_check_decode (const char input[], size_t input_length) |
std::vector< uint8_t > | base58_check_decode (const std::string &s) |
template<typename Alloc > | |
std::string | base58_check_encode (const std::vector< uint8_t, Alloc > &vec) |
std::string | base58_check_encode (const uint8_t input[], size_t input_length) |
std::vector< uint8_t > | base58_decode (const char input[], size_t input_length) |
std::vector< uint8_t > | base58_decode (const std::string &s) |
template<typename Alloc > | |
std::string | base58_encode (const std::vector< uint8_t, Alloc > &vec) |
std::string | base58_encode (const uint8_t input[], size_t input_length) |
secure_vector< uint8_t > | base64_decode (const char input[], size_t input_length, bool ignore_ws) |
secure_vector< uint8_t > | base64_decode (const std::string &input, bool ignore_ws) |
size_t | base64_decode (uint8_t out[], const char in[], size_t input_length, size_t &input_consumed, bool final_inputs, bool ignore_ws) |
size_t | base64_decode (uint8_t output[], const char input[], size_t input_length, bool ignore_ws) |
size_t | base64_decode (uint8_t output[], const std::string &input, bool ignore_ws) |
size_t | base64_decode_max_output (size_t input_length) |
size_t | base64_encode (char out[], const uint8_t in[], size_t input_length, size_t &input_consumed, bool final_inputs) |
template<typename Alloc > | |
std::string | base64_encode (const std::vector< uint8_t, Alloc > &input) |
std::string | base64_encode (const uint8_t input[], size_t input_length) |
size_t | base64_encode_max_output (size_t input_length) |
template<typename Base > | |
size_t | base_decode (Base &&base, uint8_t output[], const char input[], size_t input_length, size_t &input_consumed, bool final_inputs, bool ignore_ws=true) |
template<typename Base > | |
size_t | base_decode_full (Base &&base, uint8_t output[], const char input[], size_t input_length, bool ignore_ws) |
template<typename Vector , typename Base > | |
Vector | base_decode_to_vec (Base &&base, const char input[], size_t input_length, bool ignore_ws) |
template<class Base > | |
size_t | base_encode (Base &&base, char output[], const uint8_t input[], size_t input_length, size_t &input_consumed, bool final_inputs) |
template<typename Base > | |
std::string | base_encode_to_string (Base &&base, const uint8_t input[], size_t input_length) |
void | bcrypt_pbkdf (uint8_t output[], size_t output_len, const char *password, size_t password_len, const uint8_t salt[], size_t salt_len, size_t rounds) |
void | bigint_add2 (word x[], size_t x_size, const word y[], size_t y_size) |
word | bigint_add2_nc (word x[], size_t x_size, const word y[], size_t y_size) |
void | bigint_add3 (word z[], const word x[], size_t x_size, const word y[], size_t y_size) |
word | bigint_add3_nc (word z[], const word x[], size_t x_size, const word y[], size_t y_size) |
int32_t | bigint_cmp (const word x[], size_t x_size, const word y[], size_t y_size) |
void | bigint_cnd_abs (word cnd, word x[], size_t size) |
word | bigint_cnd_add (word cnd, word x[], const word y[], size_t size) |
word | bigint_cnd_add (word cnd, word x[], word x_size, const word y[], size_t y_size) |
void | bigint_cnd_add_or_sub (CT::Mask< word > mask, word x[], const word y[], size_t size) |
word | bigint_cnd_addsub (CT::Mask< word > mask, word x[], const word y[], const word z[], size_t size) |
word | bigint_cnd_sub (word cnd, word x[], const word y[], size_t size) |
word | bigint_cnd_sub (word cnd, word x[], size_t x_size, const word y[], size_t y_size) |
void | bigint_cnd_swap (word cnd, word x[], word y[], size_t size) |
void | bigint_comba_mul16 (word z[32], const word x[16], const word y[16]) |
void | bigint_comba_mul24 (word z[48], const word x[24], const word y[24]) |
void | bigint_comba_mul4 (word z[8], const word x[4], const word y[4]) |
void | bigint_comba_mul6 (word z[12], const word x[6], const word y[6]) |
void | bigint_comba_mul8 (word z[16], const word x[8], const word y[8]) |
void | bigint_comba_mul9 (word z[18], const word x[9], const word y[9]) |
void | bigint_comba_sqr16 (word z[32], const word x[16]) |
void | bigint_comba_sqr24 (word z[48], const word x[24]) |
void | bigint_comba_sqr4 (word z[8], const word x[4]) |
void | bigint_comba_sqr6 (word z[12], const word x[6]) |
void | bigint_comba_sqr8 (word z[16], const word x[8]) |
void | bigint_comba_sqr9 (word z[18], const word x[9]) |
CT::Mask< word > | bigint_ct_is_eq (const word x[], size_t x_size, const word y[], size_t y_size) |
CT::Mask< word > | bigint_ct_is_lt (const word x[], size_t x_size, const word y[], size_t y_size, bool lt_or_equal=false) |
word | bigint_divop (word n1, word n0, word d) |
word | bigint_linmul2 (word x[], size_t x_size, word y) |
void | bigint_linmul3 (word z[], const word x[], size_t x_size, word y) |
void | bigint_mod_sub (word t[], const word s[], const word mod[], size_t mod_sw, word ws[]) |
template<size_t N> | |
void | bigint_mod_sub_n (word t[], const word s[], const word mod[], word ws[]) |
word | bigint_modop (word n1, word n0, word d) |
void | bigint_monty_redc (word z[], const word p[], size_t p_size, word p_dash, word ws[], size_t ws_size) |
void | bigint_monty_redc_16 (word z[], const word p[16], word p_dash, word ws[]) |
void | bigint_monty_redc_24 (word z[], const word p[24], word p_dash, word ws[]) |
void | bigint_monty_redc_32 (word z[], const word p[32], word p_dash, word ws[]) |
void | bigint_monty_redc_4 (word z[], const word p[4], word p_dash, word ws[]) |
void | bigint_monty_redc_6 (word z[], const word p[6], word p_dash, word ws[]) |
void | bigint_monty_redc_8 (word z[], const word p[8], word p_dash, word ws[]) |
void | bigint_monty_redc_generic (word z[], size_t z_size, const word p[], size_t p_size, word p_dash, word ws[]) |
void | bigint_mul (word z[], size_t z_size, const word x[], size_t x_size, size_t x_sw, const word y[], size_t y_size, size_t y_sw, word workspace[], size_t ws_size) |
void | bigint_shl1 (word x[], size_t x_size, size_t x_words, size_t word_shift, size_t bit_shift) |
void | bigint_shl2 (word y[], const word x[], size_t x_size, size_t word_shift, size_t bit_shift) |
void | bigint_shr1 (word x[], size_t x_size, size_t word_shift, size_t bit_shift) |
void | bigint_shr2 (word y[], const word x[], size_t x_size, size_t word_shift, size_t bit_shift) |
void | bigint_sqr (word z[], size_t z_size, const word x[], size_t x_size, size_t x_sw, word workspace[], size_t ws_size) |
word | bigint_sub2 (word x[], size_t x_size, const word y[], size_t y_size) |
void | bigint_sub2_rev (word x[], const word y[], size_t y_size) |
word | bigint_sub3 (word z[], const word x[], size_t x_size, const word y[], size_t y_size) |
CT::Mask< word > | bigint_sub_abs (word z[], const word x[], const word y[], size_t N, word ws[]) |
int32_t | bigint_sub_abs (word z[], const word x[], size_t x_size, const word y[], size_t y_size) |
template<typename T > | |
constexpr T | bit_permute_step (T x, T mask, size_t shift) |
size_t | bit_size_to_32bit_size (size_t bit_size) |
size_t | bit_size_to_byte_size (size_t bit_size) |
void | blamka_ssse3 (uint64_t T[128]) |
const BotanErrorCategory & | botan_category () noexcept |
template<typename T > | |
constexpr void | bswap_4 (T x[4]) |
template<typename T , typename Alloc , typename Alloc2 > | |
size_t | buffer_insert (std::vector< T, Alloc > &buf, size_t buf_offset, const std::vector< T, Alloc2 > &input) |
template<typename T , typename Alloc > | |
size_t | buffer_insert (std::vector< T, Alloc > &buf, size_t buf_offset, const T input[], size_t input_length) |
template<size_t S, int64_t MUL = 1> | |
void | carry (int64_t &h0, int64_t &h1) |
template<size_t S> | |
void | carry0 (int32_t &h0, int32_t &h1) |
template<size_t S> | |
void | carry0 (int64_t &h0, int64_t &h1) |
uint64_t | carry_shift (const donna128 &a, size_t shift) |
uint8_t * | cast_char_ptr_to_uint8 (char *s) |
const uint8_t * | cast_char_ptr_to_uint8 (const char *s) |
const char * | cast_uint8_ptr_to_char (const uint8_t *b) |
char * | cast_uint8_ptr_to_char (uint8_t *b) |
void | CECPQ1_accept (uint8_t *shared_key, uint8_t *accept_message, const uint8_t *offer_message, RandomNumberGenerator &rng) |
void | CECPQ1_accept (uint8_t shared_key[CECPQ1_SHARED_KEY_BYTES], uint8_t send[CECPQ1_ACCEPT_BYTES], const uint8_t received[CECPQ1_OFFER_BYTES], RandomNumberGenerator &rng) |
void | CECPQ1_finish (uint8_t *shared_key, const CECPQ1_key &offer_key, const uint8_t *accept_message) |
void | CECPQ1_finish (uint8_t shared_key[CECPQ1_SHARED_KEY_BYTES], const CECPQ1_key &offer_key, const uint8_t received[CECPQ1_ACCEPT_BYTES]) |
void | CECPQ1_offer (uint8_t *offer_message, CECPQ1_key *offer_key_output, RandomNumberGenerator &rng) |
void | CECPQ1_offer (uint8_t send[CECPQ1_OFFER_BYTES], CECPQ1_key *offer_key_output, RandomNumberGenerator &rng) |
template<typename T > | |
constexpr uint8_t | ceil_log2 (T x) |
bool | check_bcrypt (const std::string &pass, const std::string &hash) |
bool | check_passhash9 (const std::string &pass, const std::string &hash) |
size_t | checked_add (size_t x, size_t y, const char *file, int line) |
template<typename RT , typename AT > | |
RT | checked_cast_to (AT i) |
template<typename T > | |
constexpr T | choose (T mask, T a, T b) |
PK_Signer * | choose_sig_format (const Private_Key &key, const std::map< std::string, std::string > &opts, RandomNumberGenerator &rng, const std::string &hash_fn, AlgorithmIdentifier &sig_algo) |
PK_Signer * | choose_sig_format (const Private_Key &key, RandomNumberGenerator &rng, const std::string &hash_fn, AlgorithmIdentifier &sig_algo) |
std::string | clean_ws (const std::string &s) |
constexpr void | clear_bytes (void *ptr, size_t bytes) |
template<typename T > | |
constexpr void | clear_mem (T *ptr, size_t n) |
uint64_t | combine_lower (const donna128 &a, size_t s1, const donna128 &b, size_t s2) |
void | commoncrypto_adjust_key_size (const uint8_t key[], size_t length, const CommonCryptor_Opts &opts, secure_vector< uint8_t > &full_key) |
CommonCryptor_Opts | commoncrypto_opts_from_algo (const std::string &algo) |
CommonCryptor_Opts | commoncrypto_opts_from_algo_name (const std::string &algo_name) |
template<typename... Ts> | |
decltype(auto) | concat (Ts &&...buffers) |
template<typename ResultT , typename... Ts> | |
ResultT | concat_as (Ts &&...buffers) |
bool | constant_time_compare (const uint8_t x[], const uint8_t y[], size_t len) |
template<typename T > | |
constexpr void | copy_mem (T *out, const T *in, size_t n) |
template<typename T > | |
void | copy_out_be (uint8_t out[], size_t out_bytes, const T in[]) |
template<typename T > | |
void | copy_out_le (uint8_t out[], size_t out_bytes, const T in[]) |
template<typename T , typename Alloc > | |
void | copy_out_vec_be (uint8_t out[], size_t out_bytes, const std::vector< T, Alloc > &in) |
template<typename T , typename Alloc > | |
void | copy_out_vec_le (uint8_t out[], size_t out_bytes, const std::vector< T, Alloc > &in) |
std::unique_ptr< Private_Key > | create_ec_private_key (const std::string &alg_name, const EC_Group &ec_group, RandomNumberGenerator &rng) |
template<typename Alloc > | |
std::string | create_hex_fingerprint (const std::vector< uint8_t, Alloc > &vec, const std::string &hash_name) |
std::string | create_hex_fingerprint (const uint8_t bits[], size_t bits_len, const std::string &hash_name) |
std::unique_ptr< Private_Key > | create_private_key (const std::string &alg_name, RandomNumberGenerator &rng, const std::string ¶ms, const std::string &provider) |
uint8_t | ct_compare_u8 (const uint8_t x[], const uint8_t y[], size_t len) |
BigInt | ct_divide (const BigInt &x, const BigInt &y) |
void | ct_divide (const BigInt &x, const BigInt &y, BigInt &q_out, BigInt &r_out) |
void | ct_divide_word (const BigInt &x, word y, BigInt &q_out, word &r_out) |
template<typename T > | |
constexpr T | ct_is_zero (T x) |
BigInt | ct_modulo (const BigInt &x, const BigInt &y) |
template<typename T > | |
constexpr size_t | ctz (T n) |
void | curve25519_basepoint (uint8_t mypublic[32], const uint8_t secret[32]) |
void | curve25519_donna (uint8_t mypublic[32], const uint8_t secret[32], const uint8_t basepoint[32]) |
void | deallocate_memory (void *p, size_t elems, size_t elem_size) |
gf2m | decode_gf2m (const uint8_t *mem) |
size_t | dl_exponent_size (size_t bits) |
size_t | dl_work_factor (size_t bits) |
template<typename E , typename... Args> | |
void | do_throw_error (const char *file, int line, const char *func, Args... args) |
size_t | ecp_work_factor (size_t bits) |
void | ed25519_gen_keypair (uint8_t *pk, uint8_t *sk, const uint8_t seed[32]) |
void | ed25519_gen_keypair (uint8_t pk[32], uint8_t sk[64], const uint8_t seed[32]) |
void | ed25519_sign (uint8_t sig[64], const uint8_t m[], size_t mlen, const uint8_t sk[64], const uint8_t domain_sep[], size_t domain_sep_len) |
bool | ed25519_verify (const uint8_t *m, size_t mlen, const uint8_t sig[64], const uint8_t *pk, const uint8_t domain_sep[], size_t domain_sep_len) |
bool | ed25519_verify (const uint8_t msg[], size_t msg_len, const uint8_t sig[64], const uint8_t pk[32], const uint8_t domain_sep[], size_t domain_sep_len) |
uint32_t | encode_gf2m (gf2m to_enc, uint8_t *mem) |
template<typename T > | |
uint16_t | expand_mask_16bit (T tst) |
void | expand_message_xmd (const std::string &hash_fn, uint8_t output[], size_t output_len, const uint8_t input[], size_t input_len, const uint8_t domain_sep[], size_t domain_sep_len) |
template<typename T > | |
constexpr T | expand_top_bit (T a) |
void | fe_0 (fe &x) |
void | fe_1 (fe &x) |
void | fe_add (fe &x, const fe &a, const fe &b) |
void | fe_copy (fe &a, const fe &b) |
void | fe_frombytes (fe &x, const uint8_t *b) |
void | fe_invert (fe &x, const fe &z) |
int | fe_isnegative (const fe &x) |
int | fe_isnonzero (const fe &x) |
void | fe_mul (fe &x, const fe &a, const fe &b) |
void | fe_neg (fe &x, const fe &z) |
void | fe_pow22523 (fe &x, const fe &y) |
void | fe_sq (fe &x, const fe &z) |
void | fe_sq2 (fe &x, const fe &z) |
void | fe_sq_iter (fe &x, const fe &z, size_t iter) |
void | fe_sub (fe &x, const fe &a, const fe &b) |
void | fe_tobytes (uint8_t *b, const fe &x) |
secure_vector< gf2m > | find_roots_gf2m_decomp (const polyn_gf2m &polyn, size_t code_length) |
void | gamma (SIMD_4x32 &A0, SIMD_4x32 &A1, SIMD_4x32 &A2, SIMD_4x32 &A3) |
BigInt | gcd (const BigInt &a, const BigInt &b) |
void | ge_double_scalarmult_vartime (uint8_t out[32], const uint8_t *a, const ge_p3 *A, const uint8_t *b) |
void | ge_double_scalarmult_vartime (uint8_t out[32], const uint8_t a[], const ge_p3 *A, const uint8_t b[]) |
int | ge_frombytes_negate_vartime (ge_p3 *v, const uint8_t *) |
void | ge_scalarmult_base (uint8_t out[32], const uint8_t in[32]) |
std::string | generate_bcrypt (const std::string &pass, RandomNumberGenerator &rng, uint16_t work_factor, char version) |
std::vector< uint8_t > | generate_dsa_primes (RandomNumberGenerator &rng, BigInt &p, BigInt &q, size_t pbits, size_t qbits) |
bool | generate_dsa_primes (RandomNumberGenerator &rng, BigInt &p, BigInt &q, size_t pbits, size_t qbits, const std::vector< uint8_t > &seed_c, size_t offset) |
McEliece_PrivateKey | generate_mceliece_key (RandomNumberGenerator &rng, size_t ext_deg, size_t code_length, size_t t) |
std::string | generate_passhash9 (const std::string &pass, RandomNumberGenerator &rng, uint16_t work_factor, uint8_t alg_id) |
BigInt | generate_rfc6979_nonce (const BigInt &x, const BigInt &q, const BigInt &h, const std::string &hash) |
BigInt | generate_rsa_prime (RandomNumberGenerator &keygen_rng, RandomNumberGenerator &prime_test_rng, size_t bits, const BigInt &coprime, size_t prob) |
BigInt | generate_srp6_verifier (const std::string &identifier, const std::string &password, const std::vector< uint8_t > &salt, const DL_Group &group, const std::string &hash_id) |
BigInt | generate_srp6_verifier (const std::string &identifier, const std::string &password, const std::vector< uint8_t > &salt, const std::string &group_id, const std::string &hash_id) |
AEAD_Mode * | get_aead (const std::string &name, Cipher_Dir direction) |
template<size_t B, typename T > | |
constexpr uint8_t | get_byte (T input) |
template<typename T > | |
constexpr uint8_t | get_byte_var (size_t byte_num, T input) |
Keyed_Filter * | get_cipher (const std::string &algo_spec, Cipher_Dir direction) |
Keyed_Filter * | get_cipher (const std::string &algo_spec, const SymmetricKey &key, Cipher_Dir direction) |
Keyed_Filter * | get_cipher (const std::string &algo_spec, const SymmetricKey &key, const InitializationVector &iv, Cipher_Dir direction) |
Cipher_Mode * | get_cipher_mode (const std::string &algo_spec, Cipher_Dir direction, const std::string &provider="") |
std::vector< std::string > | get_files_recursive (const std::string &dir) |
KDF * | get_kdf (const std::string &algo_spec) |
PBKDF * | get_pbkdf (const std::string &algo_spec, const std::string &provider="") |
PBKDF * | get_s2k (const std::string &algo_spec) |
std::vector< std::string > | get_sig_paddings (const std::string &algo) |
gf2m | gray_to_lex (gf2m gray) |
bool | has_filesystem_impl () |
std::string | hash_for_emsa (const std::string &algo_spec) |
PointGFp | hash_to_curve_sswu (const EC_Group &group, const std::string &hash_fn, const uint8_t input[], size_t input_len, const uint8_t domain_sep[], size_t domain_sep_len, bool random_oracle) |
std::vector< uint8_t > | hex_decode (const char input[], size_t input_length, bool ignore_ws) |
std::vector< uint8_t > | hex_decode (const std::string &input, bool ignore_ws) |
size_t | hex_decode (uint8_t output[], const char input[], size_t input_length, bool ignore_ws) |
size_t | hex_decode (uint8_t output[], const char input[], size_t input_length, size_t &input_consumed, bool ignore_ws) |
size_t | hex_decode (uint8_t output[], const std::string &input, bool ignore_ws) |
secure_vector< uint8_t > | hex_decode_locked (const char input[], size_t input_length, bool ignore_ws) |
secure_vector< uint8_t > | hex_decode_locked (const std::string &input, bool ignore_ws) |
void | hex_encode (char output[], const uint8_t input[], size_t input_length, bool uppercase) |
template<typename Alloc > | |
std::string | hex_encode (const std::vector< uint8_t, Alloc > &input, bool uppercase=true) |
std::string | hex_encode (const uint8_t input[], size_t input_length, bool uppercase) |
template<typename T > | |
constexpr size_t | high_bit (T n) |
secure_vector< uint8_t > | hkdf_expand_label (const std::string &hash_fn, const uint8_t secret[], size_t secret_len, const std::string &label, const uint8_t hash_val[], size_t hash_val_len, size_t length) |
template<typename... Alts, typename... Ts> | |
constexpr bool | holds_any_of (const std::variant< Ts... > &v) noexcept |
bool | host_wildcard_match (const std::string &issued_, const std::string &host_) |
uint8_t | ieee1363_hash_id (const std::string &name) |
size_t | if_work_factor (size_t bits) |
void | initialize_allocator () |
bool | intersects (ASN1_Class x, ASN1_Class y) |
BigInt | inverse_mod (const BigInt &n, const BigInt &mod) |
std::string | ipv4_to_string (uint32_t ip) |
bool | is_bailie_psw_probable_prime (const BigInt &n) |
bool | is_bailie_psw_probable_prime (const BigInt &n, const Modular_Reducer &mod_n) |
bool | is_lucas_probable_prime (const BigInt &C, const Modular_Reducer &mod_C) |
bool | is_miller_rabin_probable_prime (const BigInt &n, const Modular_Reducer &mod_n, RandomNumberGenerator &rng, size_t test_iterations) |
bool | is_passhash9_alg_supported (uint8_t alg_id) |
BigInt | is_perfect_square (const BigInt &C) |
template<typename T > | |
constexpr bool | is_power_of_2 (T arg) |
bool | is_prime (const BigInt &n, RandomNumberGenerator &rng, size_t prob, bool is_random) |
int32_t | jacobi (const BigInt &a, const BigInt &n) |
std::string | key_constraints_to_string (Key_Constraints constraints) |
std::string | latin1_to_utf8 (const uint8_t chars[], size_t len) |
BigInt | lcm (const BigInt &a, const BigInt &b) |
gf2m | lex_to_gray (gf2m lex) |
uint64_t | load_3 (const uint8_t in[3]) |
uint64_t | load_4 (const uint8_t *in) |
template<typename T > | |
constexpr T | load_be (const uint8_t in[], size_t off) |
template<typename T > | |
constexpr void | load_be (const uint8_t in[], T &x0, T &x1) |
template<typename T > | |
constexpr void | load_be (const uint8_t in[], T &x0, T &x1, T &x2, T &x3) |
template<typename T > | |
constexpr void | load_be (const uint8_t in[], T &x0, T &x1, T &x2, T &x3, T &x4, T &x5, T &x6, T &x7) |
template<typename T > | |
constexpr void | load_be (T out[], const uint8_t in[], size_t count) |
template<> | |
constexpr uint16_t | load_be< uint16_t > (const uint8_t in[], size_t off) |
template<> | |
constexpr uint32_t | load_be< uint32_t > (const uint8_t in[], size_t off) |
template<> | |
constexpr uint64_t | load_be< uint64_t > (const uint8_t in[], size_t off) |
template<typename T > | |
constexpr T | load_le (const uint8_t in[], size_t off) |
template<typename T > | |
constexpr void | load_le (const uint8_t in[], T &x0, T &x1) |
template<typename T > | |
constexpr void | load_le (const uint8_t in[], T &x0, T &x1, T &x2, T &x3) |
template<typename T > | |
constexpr void | load_le (const uint8_t in[], T &x0, T &x1, T &x2, T &x3, T &x4, T &x5, T &x6, T &x7) |
template<typename T > | |
constexpr void | load_le (T out[], const uint8_t in[], size_t count) |
template<> | |
constexpr uint16_t | load_le< uint16_t > (const uint8_t in[], size_t off) |
template<> | |
constexpr uint32_t | load_le< uint32_t > (const uint8_t in[], size_t off) |
template<> | |
constexpr uint64_t | load_le< uint64_t > (const uint8_t in[], size_t off) |
std::unique_ptr< Private_Key > | load_private_key (const AlgorithmIdentifier &alg_id, const secure_vector< uint8_t > &key_bits) |
std::unique_ptr< Public_Key > | load_public_key (const AlgorithmIdentifier &alg_id, const std::vector< uint8_t > &key_bits) |
size_t | low_zero_bits (const BigInt &n) |
template<typename T > | |
constexpr T | majority (T a, T b, T c) |
std::unique_ptr< BlockCipher > | make_commoncrypto_block_cipher (const std::string &name) |
std::unique_ptr< Cipher_Mode > | make_commoncrypto_cipher_mode (const std::string &name, Cipher_Dir direction) |
std::unique_ptr< HashFunction > | make_commoncrypto_hash (const std::string &name) |
Compression_Algorithm * | make_compressor (const std::string &type) |
Decompression_Algorithm * | make_decompressor (const std::string &type) |
boost::system::error_code | make_error_code (Botan::ErrorType e) |
constexpr uint16_t | make_uint16 (uint8_t i0, uint8_t i1) |
constexpr uint32_t | make_uint32 (uint8_t i0, uint8_t i1, uint8_t i2, uint8_t i3) |
constexpr uint64_t | make_uint64 (uint8_t i0, uint8_t i1, uint8_t i2, uint8_t i3, uint8_t i4, uint8_t i5, uint8_t i6, uint8_t i7) |
template<typename K , typename V > | |
std::set< K > | map_keys_as_set (const std::map< K, V > &kv) |
template<typename T , typename Pred > | |
void | map_remove_if (Pred pred, T &assoc) |
secure_vector< uint8_t > | mceliece_decrypt (secure_vector< gf2m > &error_pos, const uint8_t *ciphertext, size_t ciphertext_len, const McEliece_PrivateKey &key) |
void | mceliece_decrypt (secure_vector< uint8_t > &plaintext, secure_vector< uint8_t > &error_mask, const uint8_t ciphertext[], size_t ciphertext_len, const McEliece_PrivateKey &key) |
void | mceliece_decrypt (secure_vector< uint8_t > &plaintext_out, secure_vector< uint8_t > &error_mask_out, const secure_vector< uint8_t > &ciphertext, const McEliece_PrivateKey &key) |
void | mceliece_encrypt (secure_vector< uint8_t > &ciphertext_out, secure_vector< uint8_t > &error_mask_out, const secure_vector< uint8_t > &plaintext, const McEliece_PublicKey &key, RandomNumberGenerator &rng) |
size_t | mceliece_work_factor (size_t n, size_t t) |
void | mgf1_mask (HashFunction &hash, const uint8_t in[], size_t in_len, uint8_t out[], size_t out_len) |
size_t | miller_rabin_test_iterations (size_t n_bits, size_t prob, bool random) |
BigInt | monty_execute (const Montgomery_Exponentation_State &precomputed_state, const BigInt &k, size_t max_k_bits) |
BigInt | monty_execute_vartime (const Montgomery_Exponentation_State &precomputed_state, const BigInt &k) |
BigInt | monty_exp (std::shared_ptr< const Montgomery_Params > params_p, const BigInt &g, const BigInt &k, size_t max_k_bits) |
BigInt | monty_exp_vartime (std::shared_ptr< const Montgomery_Params > params_p, const BigInt &g, const BigInt &k) |
word | monty_inverse (word a) |
BigInt | monty_multi_exp (const std::shared_ptr< const Montgomery_Params > ¶ms_p, const BigInt &x_bn, const BigInt &z1, const BigInt &y_bn, const BigInt &z2) |
std::shared_ptr< const Montgomery_Exponentation_State > | monty_precompute (const std::shared_ptr< const Montgomery_Params > ¶ms, const BigInt &g, size_t window_bits, bool const_time) |
void | mul64x64_128 (uint64_t a, uint64_t b, uint64_t *lo, uint64_t *hi) |
PointGFp | multi_exponentiate (const PointGFp &p1, const BigInt &z1, const PointGFp &p2, const BigInt &z2) |
template<typename K , typename V > | |
void | multimap_insert (std::multimap< K, V > &multimap, const K &key, const V &value) |
void | newhope_keygen (uint8_t *send, poly *sk, RandomNumberGenerator &rng, Newhope_Mode mode) |
void | newhope_keygen (uint8_t send[NEWHOPE_SENDABYTES], newhope_poly *sk, RandomNumberGenerator &rng, Newhope_Mode=Newhope_Mode::SHA3) |
void | newhope_shareda (uint8_t *sharedkey, const poly *sk, const uint8_t received[], Newhope_Mode mode) |
void | newhope_shareda (uint8_t sharedkey[NEWHOPE_SHARED_KEY_BYTES], const newhope_poly *ska, const uint8_t *received, Newhope_Mode mode=Newhope_Mode::SHA3) |
void | newhope_sharedb (uint8_t *sharedkey, uint8_t *send, const uint8_t *received, RandomNumberGenerator &rng, Newhope_Mode mode) |
void | newhope_sharedb (uint8_t sharedkey[NEWHOPE_SHARED_KEY_BYTES], uint8_t send[], const uint8_t *received, RandomNumberGenerator &rng, Newhope_Mode mode=Newhope_Mode::SHA3) |
secure_vector< uint8_t > | nist_key_unwrap (const uint8_t input[], size_t input_len, const BlockCipher &bc) |
secure_vector< uint8_t > | nist_key_unwrap_padded (const uint8_t input[], size_t input_len, const BlockCipher &bc) |
std::vector< uint8_t > | nist_key_wrap (const uint8_t input[], size_t input_len, const BlockCipher &bc) |
std::vector< uint8_t > | nist_key_wrap_padded (const uint8_t input[], size_t input_len, const BlockCipher &bc) |
secure_vector< uint8_t > | oaep_find_delim (uint8_t &valid_mask, const uint8_t input[], size_t input_len, const secure_vector< uint8_t > &Phash) |
bool | operator!= (const AlgorithmIdentifier &a1, const AlgorithmIdentifier &a2) |
bool | operator!= (const ASN1_Time &, const ASN1_Time &) |
bool | operator!= (const BigInt &a, const BigInt &b) |
bool | operator!= (const BigInt &a, word b) |
bool | operator!= (const CRL_Entry &a1, const CRL_Entry &a2) |
bool | operator!= (const CurveGFp &lhs, const CurveGFp &rhs) |
bool | operator!= (const EC_Group &lhs, const EC_Group &rhs) |
bool | operator!= (const OctetString &s1, const OctetString &s2) |
bool | operator!= (const OID &a, const OID &b) |
bool | operator!= (const PointGFp &lhs, const PointGFp &rhs) |
template<typename T , typename U > | |
bool | operator!= (const secure_allocator< T > &, const secure_allocator< U > &) |
bool | operator!= (const X509_Certificate &cert1, const X509_Certificate &cert2) |
bool | operator!= (const X509_DN &dn1, const X509_DN &dn2) |
BigInt | operator% (const BigInt &n, const BigInt &mod) |
word | operator% (const BigInt &n, word mod) |
ECIES_Flags | operator& (ECIES_Flags a, ECIES_Flags b) |
PointGFp | operator* (const BigInt &scalar, const PointGFp &point) |
BigInt | operator* (const BigInt &x, const BigInt &y) |
BigInt | operator* (const BigInt &x, word y) |
donna128 | operator* (const donna128 &x, uint64_t y) |
PointGFp | operator* (const PointGFp &point, const BigInt &scalar) |
donna128 | operator* (uint64_t y, const donna128 &x) |
BigInt | operator* (word x, const BigInt &y) |
BigInt | operator+ (const BigInt &x, const BigInt &y) |
BigInt | operator+ (const BigInt &x, word y) |
donna128 | operator+ (const donna128 &x, const donna128 &y) |
donna128 | operator+ (const donna128 &x, uint64_t y) |
OctetString | operator+ (const OctetString &k1, const OctetString &k2) |
OID | operator+ (const OID &oid, uint32_t new_comp) |
PointGFp | operator+ (const PointGFp &lhs, const PointGFp &rhs) |
BigInt | operator+ (word x, const BigInt &y) |
template<typename T , typename Alloc , typename L > | |
std::vector< T, Alloc > & | operator+= (std::vector< T, Alloc > &out, const std::pair< const T *, L > &in) |
template<typename T , typename Alloc , typename L > | |
std::vector< T, Alloc > & | operator+= (std::vector< T, Alloc > &out, const std::pair< T *, L > &in) |
template<typename T , typename Alloc , typename Alloc2 > | |
std::vector< T, Alloc > & | operator+= (std::vector< T, Alloc > &out, const std::vector< T, Alloc2 > &in) |
template<typename T , typename Alloc > | |
std::vector< T, Alloc > & | operator+= (std::vector< T, Alloc > &out, T in) |
BigInt | operator- (const BigInt &x, const BigInt &y) |
BigInt | operator- (const BigInt &x, word y) |
PointGFp | operator- (const PointGFp &lhs) |
PointGFp | operator- (const PointGFp &lhs, const PointGFp &rhs) |
BigInt | operator/ (const BigInt &x, const BigInt &y) |
BigInt | operator/ (const BigInt &x, word y) |
bool | operator< (const ASN1_Time &, const ASN1_Time &) |
bool | operator< (const BigInt &a, const BigInt &b) |
bool | operator< (const BigInt &a, word b) |
bool | operator< (const OID &a, const OID &b) |
bool | operator< (const X509_DN &dn1, const X509_DN &dn2) |
BigInt | operator<< (const BigInt &x, size_t shift) |
int | operator<< (int fd, Pipe &pipe) |
std::ostream & | operator<< (std::ostream &os, const GeneralName &gn) |
std::ostream & | operator<< (std::ostream &os, const GeneralSubtree &gs) |
std::ostream & | operator<< (std::ostream &out, const X509_DN &dn) |
std::ostream & | operator<< (std::ostream &out, Pipe &pipe) |
std::ostream & | operator<< (std::ostream &stream, const BigInt &n) |
bool | operator<= (const ASN1_Time &, const ASN1_Time &) |
bool | operator<= (const BigInt &a, const BigInt &b) |
bool | operator<= (const BigInt &a, word b) |
bool | operator== (const AlgorithmIdentifier &a1, const AlgorithmIdentifier &a2) |
bool | operator== (const ASN1_Time &, const ASN1_Time &) |
bool | operator== (const BigInt &a, const BigInt &b) |
bool | operator== (const BigInt &a, word b) |
bool | operator== (const CRL_Entry &a1, const CRL_Entry &a2) |
bool | operator== (const OctetString &s1, const OctetString &s2) |
template<typename T , typename U > | |
bool | operator== (const secure_allocator< T > &, const secure_allocator< U > &) |
bool | operator== (const X509_DN &dn1, const X509_DN &dn2) |
bool | operator> (const ASN1_Time &, const ASN1_Time &) |
bool | operator> (const BigInt &a, const BigInt &b) |
bool | operator> (const BigInt &a, word b) |
bool | operator>= (const ASN1_Time &, const ASN1_Time &) |
bool | operator>= (const BigInt &a, const BigInt &b) |
bool | operator>= (const BigInt &a, word b) |
BigInt | operator>> (const BigInt &x, size_t shift) |
int | operator>> (int fd, Pipe &pipe) |
std::istream & | operator>> (std::istream &in, Pipe &pipe) |
std::istream & | operator>> (std::istream &in, X509_DN &dn) |
std::istream & | operator>> (std::istream &stream, BigInt &n) |
OctetString | operator^ (const OctetString &k1, const OctetString &k2) |
template<typename Alloc , typename Alloc2 > | |
std::vector< uint8_t, Alloc > & | operator^= (std::vector< uint8_t, Alloc > &out, const std::vector< uint8_t, Alloc2 > &in) |
ASN1_Class | operator| (ASN1_Class x, ASN1_Class y) |
uint32_t | operator| (ASN1_Class x, ASN1_Type y) |
uint32_t | operator| (ASN1_Type x, ASN1_Class y) |
ASN1_Type | operator| (ASN1_Type x, ASN1_Type y) |
donna128 | operator| (const donna128 &x, const donna128 &y) |
ECIES_Flags | operator| (ECIES_Flags a, ECIES_Flags b) |
template<typename Alloc > | |
PointGFp | OS2ECP (const std::vector< uint8_t, Alloc > &data, const CurveGFp &curve) |
std::pair< BigInt, BigInt > | OS2ECP (const uint8_t data[], size_t data_len, const BigInt &curve_p, const BigInt &curve_a, const BigInt &curve_b) |
PointGFp | OS2ECP (const uint8_t data[], size_t data_len, const CurveGFp &curve) |
template<class... Ts> | |
overloaded (Ts...) -> overloaded< Ts... > | |
std::vector< std::string > | parse_algorithm_name (const std::string &namex) |
bool | passes_miller_rabin_test (const BigInt &n, const Modular_Reducer &mod_n, const std::shared_ptr< Montgomery_Params > &monty_n, const BigInt &a) |
secure_vector< uint8_t > | pbes2_decrypt (const secure_vector< uint8_t > &key_bits, const std::string &passphrase, const std::vector< uint8_t > ¶ms) |
std::pair< AlgorithmIdentifier, std::vector< uint8_t > > | pbes2_encrypt (const secure_vector< uint8_t > &key_bits, const std::string &passphrase, std::chrono::milliseconds msec, const std::string &cipher, const std::string &digest, RandomNumberGenerator &rng) |
std::pair< AlgorithmIdentifier, std::vector< uint8_t > > | pbes2_encrypt_iter (const secure_vector< uint8_t > &key_bits, const std::string &passphrase, size_t pbkdf_iter, const std::string &cipher, const std::string &digest, RandomNumberGenerator &rng) |
std::pair< AlgorithmIdentifier, std::vector< uint8_t > > | pbes2_encrypt_msec (const secure_vector< uint8_t > &key_bits, const std::string &passphrase, std::chrono::milliseconds msec, size_t *out_iterations_if_nonnull, const std::string &cipher, const std::string &digest, RandomNumberGenerator &rng) |
size_t | pbkdf2 (MessageAuthenticationCode &prf, uint8_t out[], size_t out_len, const std::string &password, const uint8_t salt[], size_t salt_len, size_t iterations, std::chrono::milliseconds msec) |
void | pbkdf2 (MessageAuthenticationCode &prf, uint8_t out[], size_t out_len, const uint8_t salt[], size_t salt_len, size_t iterations) |
std::vector< uint8_t > | pkcs_hash_id (const std::string &name) |
void | poly_double_n (uint8_t buf[], size_t n) |
void | poly_double_n (uint8_t out[], const uint8_t in[], size_t n) |
void | poly_double_n_le (uint8_t out[], const uint8_t in[], size_t n) |
bool | poly_double_supported_size (size_t n) |
BigInt | power_mod (const BigInt &base, const BigInt &exp, const BigInt &mod) |
BOTAN_TEST_API const BigInt & | prime_p192 () |
BOTAN_TEST_API const BigInt & | prime_p224 () |
BOTAN_TEST_API const BigInt & | prime_p256 () |
BOTAN_TEST_API const BigInt & | prime_p384 () |
BOTAN_TEST_API const BigInt & | prime_p521 () |
std::vector< std::string > | probe_provider_private_key (const std::string &alg_name, const std::vector< std::string > &possible) |
template<typename T > | |
std::vector< std::string > | probe_providers_of (const std::string &algo_spec, const std::vector< std::string > &possible={ "base" }) |
gf2m | random_code_element (uint16_t code_length, RandomNumberGenerator &rng) |
gf2m | random_gf2m (RandomNumberGenerator &rng) |
BigInt | random_prime (RandomNumberGenerator &rng, size_t bits, const BigInt &coprime, size_t equiv, size_t modulo, size_t prob) |
BigInt | random_safe_prime (RandomNumberGenerator &rng, size_t bits) |
std::map< std::string, std::string > | read_cfg (std::istream &is) |
BOTAN_TEST_API std::map< std::string, std::string > | read_kv (const std::string &kv) |
void | redc_mul (int64_t &s1, int64_t &s2, int64_t &s3, int64_t &s4, int64_t &s5, int64_t &s6, int64_t &X) |
BOTAN_TEST_API void | redc_p192 (BigInt &x, secure_vector< word > &ws) |
BOTAN_TEST_API void | redc_p224 (BigInt &x, secure_vector< word > &ws) |
BOTAN_TEST_API void | redc_p256 (BigInt &x, secure_vector< word > &ws) |
BOTAN_TEST_API void | redc_p384 (BigInt &x, secure_vector< word > &ws) |
BOTAN_TEST_API void | redc_p521 (BigInt &x, secure_vector< word > &ws) |
constexpr uint16_t | reverse_bytes (uint16_t x) |
constexpr uint32_t | reverse_bytes (uint32_t x) |
constexpr uint64_t | reverse_bytes (uint64_t x) |
secure_vector< uint8_t > | rfc3394_keyunwrap (const secure_vector< uint8_t > &key, const SymmetricKey &kek) |
secure_vector< uint8_t > | rfc3394_keywrap (const secure_vector< uint8_t > &key, const SymmetricKey &kek) |
size_t | RFC4880_decode_count (uint8_t iter) |
uint8_t | RFC4880_encode_count (size_t desired_iterations) |
size_t | RFC4880_round_iterations (size_t iterations) |
template<size_t R> | |
SIMD_4x32 | rotl (SIMD_4x32 input) |
template<size_t R> | |
SIMD_8x32 | rotl (SIMD_8x32 input) |
template<size_t ROT, typename T > | |
constexpr T | rotl (T input) |
template<typename T > | |
constexpr T | rotl_var (T input, size_t rot) |
template<size_t R> | |
SIMD_4x32 | rotr (SIMD_4x32 input) |
template<size_t R> | |
SIMD_8x32 | rotr (SIMD_8x32 input) |
template<size_t ROT, typename T > | |
constexpr T | rotr (T input) |
template<typename T > | |
constexpr T | rotr_var (T input, size_t rot) |
template<typename T > | |
constexpr T | round_down (T n, T align_to) |
size_t | round_up (size_t n, size_t align_to) |
std::string | runtime_version_check (uint32_t major, uint32_t minor, uint32_t patch) |
template<typename T > | |
bool | same_mem (const T *p1, const T *p2, size_t n) |
void | sc_muladd (uint8_t *, const uint8_t *, const uint8_t *, const uint8_t *) |
void | sc_reduce (uint8_t *) |
void | scrypt (uint8_t output[], size_t output_len, const char *password, size_t password_len, const uint8_t salt[], size_t salt_len, size_t N, size_t r, size_t p) |
void | scrypt (uint8_t output[], size_t output_len, const std::string &password, const uint8_t salt[], size_t salt_len, size_t N, size_t r, size_t p) |
template<typename K , typename V , typename R > | |
R | search_map (const std::map< K, V > &mapping, const K &key, const R &null_result, const R &found_result) |
template<typename K , typename V > | |
V | search_map (const std::map< K, V > &mapping, const K &key, const V &null_result=V()) |
void | secure_scrub_memory (void *ptr, size_t n) |
constexpr void | set_mem (uint8_t *ptr, size_t n, uint8_t val) |
void | SHA3_round (uint64_t T[25], const uint64_t A[25], uint64_t RC) |
template<size_t S> | |
SIMD_4x32 | shl (SIMD_4x32 input) |
template<size_t S> | |
SIMD_8x32 | shl (SIMD_8x32 input) |
const char * | short_version_cstr () |
std::string | short_version_string () |
bool | sig_algo_and_pad_ok (const std::string &algo, const std::string &padding) |
template<typename T > | |
constexpr size_t | significant_bytes (T n) |
std::vector< uint8_t > | sm2_compute_za (HashFunction &hash, const std::string &user_id, const EC_Group &domain, const PointGFp &pubkey) |
std::vector< std::string > | split_on (const std::string &str, char delim) |
BigInt | sqrt_modulo_prime (const BigInt &a, const BigInt &p) |
BigInt | square (const BigInt &x) |
std::pair< BigInt, SymmetricKey > | srp6_client_agree (const std::string &identifier, const std::string &password, const DL_Group &group, const std::string &hash_id, const std::vector< uint8_t > &salt, const BigInt &B, const size_t a_bits, RandomNumberGenerator &rng) |
std::pair< BigInt, SymmetricKey > | srp6_client_agree (const std::string &identifier, const std::string &password, const std::string &group_id, const std::string &hash_id, const std::vector< uint8_t > &salt, const BigInt &B, RandomNumberGenerator &rng) |
std::string | srp6_group_identifier (const BigInt &N, const BigInt &g) |
constexpr void | store_be (uint16_t in, uint8_t out[2]) |
constexpr void | store_be (uint32_t in, uint8_t out[4]) |
constexpr void | store_be (uint64_t in, uint8_t out[8]) |
template<typename T > | |
constexpr void | store_be (uint8_t out[], T x0, T x1) |
template<typename T > | |
constexpr void | store_be (uint8_t out[], T x0, T x1, T x2, T x3) |
template<typename T > | |
constexpr void | store_be (uint8_t out[], T x0, T x1, T x2, T x3, T x4, T x5, T x6, T x7) |
constexpr void | store_le (uint16_t in, uint8_t out[2]) |
constexpr void | store_le (uint32_t in, uint8_t out[4]) |
constexpr void | store_le (uint64_t in, uint8_t out[8]) |
template<typename T > | |
constexpr void | store_le (uint8_t out[], T x0, T x1) |
template<typename T > | |
constexpr void | store_le (uint8_t out[], T x0, T x1, T x2, T x3) |
template<typename T > | |
constexpr void | store_le (uint8_t out[], T x0, T x1, T x2, T x3, T x4, T x5, T x6, T x7) |
std::string | string_join (const std::vector< std::string > &strs, char delim) |
uint32_t | string_to_ipv4 (const std::string &str) |
template<typename T > | |
constexpr void | swap_bits (T &x, T &y, T mask, size_t shift) |
std::vector< polyn_gf2m > | syndrome_init (polyn_gf2m const &generator, std::vector< gf2m > const &support, int n) |
RandomNumberGenerator & | system_rng () |
void | theta (SIMD_4x32 &A0, SIMD_4x32 &A1, SIMD_4x32 &A2, SIMD_4x32 &A3, const SIMD_4x32 &K0, const SIMD_4x32 &K1, const SIMD_4x32 &K2, const SIMD_4x32 &K3) |
void | throw_invalid_argument (const char *message, const char *func, const char *file) |
void | throw_invalid_state (const char *expr, const char *func, const char *file) |
std::vector< uint8_t > | to_byte_vector (const std::string &s) |
const char * | to_string (Certificate_Status_Code code) |
std::string | to_string (const secure_vector< uint8_t > &bytes) |
std::string | to_string (ErrorType type) |
Convert an ErrorType to string. More... | |
uint32_t | to_u32bit (const std::string &str) |
uint16_t | to_uint16 (const std::string &str) |
std::string | tolower_string (const std::string &in) |
template<class To , class From > | |
constexpr To | typecast_copy (const From *src) noexcept |
template<typename T > | |
constexpr void | typecast_copy (T &out, const uint8_t in[]) |
template<typename T > | |
constexpr void | typecast_copy (T out[], const uint8_t in[], size_t N) |
template<typename T > | |
constexpr void | typecast_copy (uint8_t out[], T in) |
template<typename T > | |
constexpr void | typecast_copy (uint8_t out[], T in[], size_t N) |
std::string | ucs2_to_utf8 (const uint8_t ucs2[], size_t len) |
std::string | ucs4_to_utf8 (const uint8_t ucs4[], size_t len) |
template<typename T > | |
std::vector< T > | unlock (const secure_vector< T > &in) |
BOTAN_FORCE_INLINE void | unreachable () |
template<typename T > | |
bool | value_exists (const std::vector< T > &vec, const T &val) |
constexpr size_t | var_ctz32 (uint32_t n) |
void | vartime_divide (const BigInt &x, const BigInt &y_arg, BigInt &q_out, BigInt &r_out) |
void | verify_cert_constraints_valid_for_key_type (const Public_Key &pub_key, Key_Constraints constraints) |
const char * | version_cstr () |
uint32_t | version_datestamp () |
uint32_t | version_major () |
uint32_t | version_minor () |
uint32_t | version_patch () |
std::string | version_string () |
void | word3_add (word *w2, word *w1, word *w0, word x) |
void | word3_muladd (word *w2, word *w1, word *w0, word x, word y) |
void | word3_muladd_2 (word *w2, word *w1, word *w0, word x, word y) |
word | word8_add2 (word x[8], const word y[8], word carry) |
word | word8_add3 (word z[8], const word x[8], const word y[8], word carry) |
word | word8_linmul2 (word x[8], word y, word carry) |
word | word8_linmul3 (word z[8], const word x[8], word y, word carry) |
word | word8_madd3 (word z[8], const word x[8], word y, word carry) |
word | word8_sub2 (word x[8], const word y[8], word carry) |
word | word8_sub2_rev (word x[8], const word y[8], word carry) |
word | word8_sub3 (word z[8], const word x[8], const word y[8], word carry) |
word | word_add (word x, word y, word *carry) |
word | word_madd2 (word a, word b, word *c) |
word | word_madd3 (word a, word b, word c, word *d) |
word | word_sub (word x, word y, word *carry) |
Path_Validation_Result | x509_path_validate (const std::vector< X509_Certificate > &end_certs, const Path_Validation_Restrictions &restrictions, const Certificate_Store &store, const std::string &hostname, Usage_Type usage, std::chrono::system_clock::time_point when, std::chrono::milliseconds ocsp_timeout, const std::vector< std::optional< OCSP::Response > > &ocsp_resp) |
Path_Validation_Result | x509_path_validate (const std::vector< X509_Certificate > &end_certs, const Path_Validation_Restrictions &restrictions, const std::vector< Certificate_Store * > &trusted_roots, const std::string &hostname, Usage_Type usage, std::chrono::system_clock::time_point ref_time, std::chrono::milliseconds ocsp_timeout, const std::vector< std::optional< OCSP::Response > > &ocsp_resp) |
Path_Validation_Result | x509_path_validate (const X509_Certificate &end_cert, const Path_Validation_Restrictions &restrictions, const Certificate_Store &store, const std::string &hostname, Usage_Type usage, std::chrono::system_clock::time_point when, std::chrono::milliseconds ocsp_timeout, const std::vector< std::optional< OCSP::Response > > &ocsp_resp) |
Path_Validation_Result | x509_path_validate (const X509_Certificate &end_cert, const Path_Validation_Restrictions &restrictions, const std::vector< Certificate_Store * > &trusted_roots, const std::string &hostname, Usage_Type usage, std::chrono::system_clock::time_point when, std::chrono::milliseconds ocsp_timeout, const std::vector< std::optional< OCSP::Response > > &ocsp_resp) |
template<typename Alloc , typename Alloc2 > | |
void | xor_buf (std::vector< uint8_t, Alloc > &out, const std::vector< uint8_t, Alloc2 > &in, size_t n) |
template<typename Alloc , typename Alloc2 > | |
void | xor_buf (std::vector< uint8_t, Alloc > &out, const uint8_t *in, const std::vector< uint8_t, Alloc2 > &in2, size_t n) |
template<typename Alloc > | |
void | xor_buf (std::vector< uint8_t, Alloc > &out, const uint8_t *in, size_t n) |
void | xor_buf (uint8_t out[], const uint8_t in[], const uint8_t in2[], size_t length) |
void | xor_buf (uint8_t out[], const uint8_t in[], size_t length) |
template<typename T , typename Alloc > | |
void | zap (std::vector< T, Alloc > &vec) |
template<typename T , typename Alloc > | |
void | zeroise (std::vector< T, Alloc > &vec) |
Variables | |
const std::map< const std::string, std::vector< std::string > > | allowed_signature_paddings |
const size_t | HEX_CODEC_BUFFER_SIZE = 256 |
const word | MP_WORD_MAX = ~static_cast<word>(0) |
const size_t | PRIME_TABLE_SIZE = 6541 |
const uint16_t | PRIMES [] |
const uint64_t | STREEBOG_Ax [8][256] |
const uint64_t | STREEBOG_C [12][8] |
(C) 2019 Jack Lloyd
Botan is released under the Simplified BSD License (see license.txt)
(C) 2018,2019,2021 Jack Lloyd
Botan is released under the Simplified BSD License (see license.txt)
(C) 2018,2019,2022 Jack Lloyd
Botan is released under the Simplified BSD License (see license.txt)
(C) 2018,2019 Jack Lloyd
Botan is released under the Simplified BSD License (see license.txt)
(C) 2022 Jack Lloyd
Botan is released under the Simplified BSD License (see license.txt)
(C) 2018 Jack Lloyd (C) 2018 Ribose Inc
Botan is released under the Simplified BSD License (see license.txt)
Ordinary applications should never need to include or use this header. It is exposed only for specialized applications which want to implement new versions of public key crypto without merging them as changes to the library. One actual example of such usage is an application which creates RSA signatures using a custom TPM library. Unless you're doing something like that, you don't need anything here. Instead use pubkey.h which wraps these types safely and provides a stable application-oriented API.
XMSS WOTS Addressed Private Key (C) 2016 Matthias Gierlings
Botan is released under the Simplified BSD License (see license.txt)
XMSS WOTS Addressed Public Key (C) 2016,2017 Matthias Gierlings
Botan is released under the Simplified BSD License (see license.txt)
typedef __vector unsigned int Botan::Altivec32x4 |
Definition at line 22 of file aes_power8.cpp.
typedef __vector unsigned long long Botan::Altivec64x2 |
Definition at line 21 of file aes_power8.cpp.
typedef __vector unsigned char Botan::Altivec8x16 |
Definition at line 23 of file aes_power8.cpp.
typedef BLAKE2b Botan::Blake2b |
typedef BLAKE2bMAC Botan::Blake2bMac |
Definition at line 60 of file blake2bmac.h.
using Botan::byte = typedef std::uint8_t |
typedef int32_t Botan::CCCryptorStatus |
Definition at line 23 of file commoncrypto.h.
typedef std::vector<std::set<Certificate_Status_Code> > Botan::CertificatePathStatusCodes |
This type represents the validation status of an entire certificate path. There is one set of status codes for each certificate in the path.
Definition at line 29 of file x509path.h.
typedef EC_Group Botan::EC_Domain_Params |
Definition at line 414 of file ec_group.h.
Definition at line 134 of file ed25519_fe.h.
typedef uint16_t Botan::gf2m |
Definition at line 20 of file gf2m_small_m.h.
using Botan::InitializationVector = typedef OctetString |
using Botan::lock_guard_type = typedef lock_guard<T> |
typedef MessageAuthenticationCode Botan::MAC |
typedef noop_mutex Botan::mutex_type |
typedef PK_Key_Agreement_Key Botan::PK_KA_Key |
typedef Private_Key Botan::PKCS8_PrivateKey |
typedef newhope_poly Botan::poly |
Definition at line 25 of file newhope.cpp.
typedef RandomNumberGenerator Botan::RNG |
typedef PBKDF Botan::S2K |
using Botan::s32bit = typedef std::int32_t |
using Botan::secure_deque = typedef std::deque<T, secure_allocator<T> > |
using Botan::secure_vector = typedef std::vector<T, secure_allocator<T> > |
using Botan::SecureVector = typedef secure_vector<T> |
typedef SHA_160 Botan::SHA_1 |
using Botan::SymmetricKey = typedef OctetString |
using Botan::u16bit = typedef std::uint16_t |
using Botan::u32bit = typedef std::uint32_t |
using Botan::u64bit = typedef std::uint64_t |
typedef std::vector< secure_vector< uint8_t > > Botan::wots_keysig_t |
Definition at line 20 of file xmss_common_ops.h.
Definition at line 105 of file curve25519.h.
Definition at line 104 of file curve25519.h.
typedef Public_Key Botan::X509_PublicKey |
typedef ASN1_Time Botan::X509_Time |
Definition at line 389 of file asn1_obj.h.
anonymous enum |
Enumerator | |
---|---|
SM3_BLOCK_BYTES | |
SM3_DIGEST_BYTES |
|
strong |
ASN.1 Class Tags
Enumerator | |
---|---|
Universal | |
Application | |
ContextSpecific | |
Private | |
Constructed | |
ExplicitContextSpecific | |
NoObject |
Definition at line 24 of file asn1_obj.h.
|
strong |
ASN.1 Type Tags
Definition at line 39 of file asn1_obj.h.
|
strong |
Certificate validation status code
Definition at line 17 of file pkix_enums.h.
enum Botan::Cipher_Dir : int |
The two possible directions for cipher filters, determining whether they actually perform encryption or decryption.
Enumerator | |
---|---|
ENCRYPTION | |
DECRYPTION |
Definition at line 23 of file cipher_mode.h.
|
strong |
X.509v2 CRL Reason Code.
Definition at line 118 of file pkix_enums.h.
|
strong |
The DL group encoding format variants.
Enumerator | |
---|---|
ANSI_X9_42 | |
ANSI_X9_57 | |
PKCS_3 | |
DSA_PARAMETERS | |
DH_PARAMETERS | |
ANSI_X9_42_DH_PARAMETERS | |
PKCS3_DH_PARAMETERS |
Definition at line 27 of file dl_group.h.
|
strong |
Enumerator | |
---|---|
Builtin | |
RandomlyGenerated | |
ExternalSource |
Definition at line 18 of file dl_group.h.
|
strong |
This class represents elliptic curce domain parameters
Enumerator | |
---|---|
Explicit | |
ImplicitCA | |
NamedCurve | |
EC_DOMPAR_ENC_EXPLICIT | |
EC_DOMPAR_ENC_IMPLICITCA | |
EC_DOMPAR_ENC_OID |
Definition at line 23 of file ec_group.h.
|
strong |
Enumerator | |
---|---|
Builtin | |
ExternalSource |
Definition at line 33 of file ec_group.h.
|
strong |
Definition at line 27 of file ecies.h.
|
strong |
Different types of errors that might occur
Enumerator | |
---|---|
Unknown | Some unknown error |
SystemError | An error while calling a system interface |
NotImplemented | An operation seems valid, but not supported by the current version |
OutOfMemory | Memory allocation failure |
InternalError | An internal error occurred |
IoError | An I/O error occurred |
InvalidObjectState | Invalid object state |
KeyNotSet | A key was not set on an object when this is required |
InvalidArgument | The application provided an argument which is invalid |
InvalidKeyLength | A key with invalid length was provided |
InvalidNonceLength | A nonce with invalid length was provided |
LookupError | An object type was requested but cannot be found |
EncodingFailure | Encoding a message or datum failed |
DecodingFailure | Decoding a message or datum failed |
TLSError | A TLS error (error_code will be the alert type) |
HttpError | An error during an HTTP operation |
InvalidTag | A message with an invalid authentication tag was detected |
RoughtimeError | An error during Roughtime validation |
CommonCryptoError | An error when interacting with CommonCrypto API |
Pkcs11Error | An error when interacting with a PKCS11 device |
TPMError | An error when interacting with a TPM device |
DatabaseError | An error when interacting with a database |
ZlibError | An error when interacting with zlib |
Bzip2Error | An error when interacting with bzip2 |
LzmaError | An error when interacting with lzma |
Definition at line 20 of file exceptn.h.
X.509v3 Key Constraints. If updating update copy in ffi.h
Enumerator | |
---|---|
NO_CONSTRAINTS | |
DIGITAL_SIGNATURE | |
NON_REPUDIATION | |
KEY_ENCIPHERMENT | |
DATA_ENCIPHERMENT | |
KEY_AGREEMENT | |
KEY_CERT_SIGN | |
CRL_SIGN | |
ENCIPHER_ONLY | |
DECIPHER_ONLY |
Definition at line 102 of file pkix_enums.h.
|
strong |
|
strong |
This chooses the XOF + hash for NewHope The official NewHope specification and reference implementation use SHA-3 and SHAKE-128. BoringSSL instead uses SHA-256 and AES-128 in CTR mode. CECPQ1 (x25519+NewHope) always uses BoringSSL's mode
Enumerator | |
---|---|
SHA3 | |
BoringSSL |
Definition at line 35 of file newhope.h.
|
strong |
|
strong |
Enumerator | |
---|---|
UNSPECIFIED | |
TLS_SERVER_AUTH | |
TLS_CLIENT_AUTH | |
CERTIFICATE_AUTHORITY | |
OCSP_RESPONDER | |
ENCRYPTION |
Definition at line 22 of file x509cert.h.
Return the absolute value
n | an integer |
Definition at line 22 of file numthry.h.
References Botan::BigInt::abs().
Referenced by gcd().
BOTAN_MALLOC_FN void * Botan::allocate_memory | ( | size_t | elems, |
size_t | elem_size | ||
) |
Allocate a memory buffer by some method. This should only be used for primitive types (uint8_t, uint32_t, etc).
elems | the number of elements |
elem_size | the size of each element |
Definition at line 18 of file mem_ops.cpp.
References Botan::mlock_allocator::instance().
Referenced by Botan::secure_allocator< T >::allocate().
|
inline |
Argon2 key derivation function
output | the output will be placed here |
output_len | length of output |
password | the user password |
password_len | the length of password |
salt | the salt |
salt_len | length of salt |
key | an optional secret key |
key_len | the length of key |
ad | an optional additional input |
ad_len | the length of ad |
y | the Argon2 variant (0 = Argon2d, 1 = Argon2i, 2 = Argon2id) |
p | the parallelization parameter |
M | the amount of memory to use in Kb |
t | the number of iterations to use |
Definition at line 113 of file argon2.h.
References salt_len.
bool Botan::argon2_check_pwhash | ( | const char * | password, |
size_t | password_len, | ||
const std::string & | hash | ||
) |
Check a previously created password hash
password | the password to check against |
password_len | the length of password |
hash | the stored hash to check against |
Definition at line 73 of file argon2fmt.cpp.
References base64_decode(), base64_decode_max_output(), constant_time_compare(), Botan::PasswordHashFamily::create_or_throw(), hash, split_on(), and to_u32bit().
std::string Botan::argon2_generate_pwhash | ( | const char * | password, |
size_t | password_len, | ||
RandomNumberGenerator & | rng, | ||
size_t | p, | ||
size_t | M, | ||
size_t | t, | ||
uint8_t | y, | ||
size_t | salt_len, | ||
size_t | output_len | ||
) |
Definition at line 39 of file argon2fmt.cpp.
References base64_encode(), Botan::PasswordHashFamily::create_or_throw(), Botan::RandomNumberGenerator::randomize(), salt_len, and Botan::ASN1::to_string().
std::string BOTAN_UNSTABLE_API Botan::asn1_class_to_string | ( | ASN1_Class | type | ) |
Definition at line 87 of file asn1_obj.cpp.
References Application, Constructed, ContextSpecific, NoObject, Private, Botan::ASN1::to_string(), type, and Universal.
Referenced by Botan::BER_Object::assert_is_a().
std::string BOTAN_UNSTABLE_API Botan::asn1_tag_to_string | ( | ASN1_Type | type | ) |
Definition at line 108 of file asn1_obj.cpp.
References BitString, BmpString, Boolean, Enumerated, GeneralizedTime, Ia5String, Integer, NoObject, Null, NumericString, ObjectId, OctetString, PrintableString, Sequence, Set, TeletexString, Botan::ASN1::to_string(), type, UniversalString, UtcTime, Utf8String, and VisibleString.
Referenced by Botan::BER_Object::assert_is_a().
void Botan::assertion_failure | ( | const char * | expr_str, |
const char * | assertion_made, | ||
const char * | func, | ||
const char * | file, | ||
int | line | ||
) |
Called when an assertion fails Throws an Exception object
Definition at line 37 of file assert.cpp.
secure_vector< uint8_t > Botan::base32_decode | ( | const char | input[], |
size_t | input_length, | ||
bool | ignore_ws = true |
||
) |
Perform base32 decoding
input | some base32 input |
input_length | the length of input in bytes |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 220 of file base32.cpp.
secure_vector< uint8_t > Botan::base32_decode | ( | const std::string & | input, |
bool | ignore_ws = true |
||
) |
Perform base32 decoding
input | some base32 input |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 227 of file base32.cpp.
References base32_decode().
size_t Botan::base32_decode | ( | uint8_t | output[], |
const char | input[], | ||
size_t | input_length, | ||
size_t & | input_consumed, | ||
bool | final_inputs, | ||
bool | ignore_ws = true |
||
) |
Perform base32 decoding
output | an array of at least base32_decode_max_output bytes |
input | some base32 input |
input_length | length of input in bytes |
input_consumed | is an output parameter which says how many bytes of input were actually consumed. If less than input_length, then the range input[consumed:length] should be passed in later along with more input. |
final_inputs | true iff this is the last input, in which case padding is allowed |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 195 of file base32.cpp.
References base_decode().
Referenced by base32_decode().
size_t Botan::base32_decode | ( | uint8_t | output[], |
const char | input[], | ||
size_t | input_length, | ||
bool | ignore_ws = true |
||
) |
Perform base32 decoding
output | an array of at least base32_decode_max_output bytes |
input | some base32 input |
input_length | length of input in bytes |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 205 of file base32.cpp.
References base_decode_full().
size_t Botan::base32_decode | ( | uint8_t | output[], |
const std::string & | input, | ||
bool | ignore_ws = true |
||
) |
Perform base32 decoding
output | an array of at least base32_decode_max_output bytes |
input | some base32 input |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 213 of file base32.cpp.
References base32_decode().
size_t Botan::base32_encode | ( | char | output[], |
const uint8_t | input[], | ||
size_t | input_length, | ||
size_t & | input_consumed, | ||
bool | final_inputs | ||
) |
Perform base32 encoding
output | an array of at least base32_encode_max_output bytes |
input | is some binary data |
input_length | length of input in bytes |
input_consumed | is an output parameter which says how many bytes of input were actually consumed. If less than input_length, then the range input[consumed:length] should be passed in later along with more input. |
final_inputs | true iff this is the last input, in which case padding chars will be applied if needed |
Definition at line 180 of file base32.cpp.
References base_encode().
Referenced by base32_encode().
std::string Botan::base32_encode | ( | const std::vector< uint8_t, Alloc > & | input | ) |
Perform base32 encoding
input | some input |
Definition at line 50 of file base32.h.
References base32_encode().
std::string Botan::base32_encode | ( | const uint8_t | input[], |
size_t | input_length | ||
) |
Perform base32 encoding
input | some input |
input_length | length of input in bytes |
Definition at line 189 of file base32.cpp.
References base_encode_to_string().
std::vector< uint8_t > Botan::base58_check_decode | ( | const char | input[], |
size_t | input_length | ||
) |
Perform base58 decoding with checksum
Definition at line 171 of file base58.cpp.
References base58_decode(), and load_be< uint32_t >().
Referenced by base58_check_decode().
|
inline |
Definition at line 69 of file base58.h.
References base58_check_decode().
|
inline |
Definition at line 59 of file base58.h.
References base58_check_encode().
std::string Botan::base58_check_encode | ( | const uint8_t | input[], |
size_t | input_length | ||
) |
Perform base58 encoding with checksum
Definition at line 136 of file base58.cpp.
References base58_encode(), and v.
Referenced by base58_check_encode().
std::vector< uint8_t > Botan::base58_decode | ( | const char | input[], |
size_t | input_length | ||
) |
Perform base58 decoding
This is raw base58 encoding, without the checksum
Definition at line 144 of file base58.cpp.
References v.
Referenced by base58_check_decode(), and base58_decode().
|
inline |
Definition at line 64 of file base58.h.
References base58_decode().
|
inline |
Definition at line 53 of file base58.h.
References base58_encode().
std::string Botan::base58_encode | ( | const uint8_t | input[], |
size_t | input_length | ||
) |
Perform base58 encoding
This is raw base58 encoding, without the checksum
Definition at line 130 of file base58.cpp.
References base58_encode(), and v.
Referenced by base58_check_encode(), and base58_encode().
secure_vector< uint8_t > Botan::base64_decode | ( | const char | input[], |
size_t | input_length, | ||
bool | ignore_ws = true |
||
) |
Perform base64 decoding
input | some base64 input |
input_length | the length of input in bytes |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 225 of file base64.cpp.
secure_vector< uint8_t > Botan::base64_decode | ( | const std::string & | input, |
bool | ignore_ws = true |
||
) |
Perform base64 decoding
input | some base64 input |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 232 of file base64.cpp.
References base64_decode().
size_t Botan::base64_decode | ( | uint8_t | output[], |
const char | input[], | ||
size_t | input_length, | ||
size_t & | input_consumed, | ||
bool | final_inputs, | ||
bool | ignore_ws = true |
||
) |
Perform base64 decoding
output | an array of at least base64_decode_max_output bytes |
input | some base64 input |
input_length | length of input in bytes |
input_consumed | is an output parameter which says how many bytes of input were actually consumed. If less than input_length, then the range input[consumed:length] should be passed in later along with more input. |
final_inputs | true iff this is the last input, in which case padding is allowed |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 200 of file base64.cpp.
References base_decode().
Referenced by argon2_check_pwhash(), base64_decode(), botan_base64_decode(), Botan::Roughtime::Chain::Chain(), check_passhash9(), Botan::PEM_Code::decode(), Botan::Base64_Decoder::end_msg(), Botan::Encrypted_PSK_Database::get(), Botan::Encrypted_PSK_Database::list_names(), Botan::Roughtime::servers_from_str(), and Botan::Base64_Decoder::write().
size_t Botan::base64_decode | ( | uint8_t | output[], |
const char | input[], | ||
size_t | input_length, | ||
bool | ignore_ws = true |
||
) |
Perform base64 decoding
output | an array of at least base64_decode_max_output bytes |
input | some base64 input |
input_length | length of input in bytes |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 210 of file base64.cpp.
References base_decode_full().
size_t Botan::base64_decode | ( | uint8_t | output[], |
const std::string & | input, | ||
bool | ignore_ws = true |
||
) |
Perform base64 decoding
output | an array of at least base64_decode_max_output bytes |
input | some base64 input |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 218 of file base64.cpp.
References base64_decode().
size_t Botan::base64_decode_max_output | ( | size_t | input_length | ) |
Calculate the size of output buffer for base64_decode
input_length | the length of input in bytes |
Definition at line 243 of file base64.cpp.
Referenced by argon2_check_pwhash(), and botan_base64_decode().
size_t Botan::base64_encode | ( | char | output[], |
const uint8_t | input[], | ||
size_t | input_length, | ||
size_t & | input_consumed, | ||
bool | final_inputs | ||
) |
Perform base64 encoding
output | an array of at least base64_encode_max_output bytes |
input | is some binary data |
input_length | length of input in bytes |
input_consumed | is an output parameter which says how many bytes of input were actually consumed. If less than input_length, then the range input[consumed:length] should be passed in later along with more input. |
final_inputs | true iff this is the last input, in which case padding chars will be applied if needed |
Definition at line 185 of file base64.cpp.
References base_encode().
Referenced by argon2_generate_pwhash(), Botan::OCSP::Request::base64_encode(), base64_encode(), botan_base64_encode(), Botan::PEM_Code::encode(), generate_passhash9(), Botan::Encrypted_PSK_Database::get(), Botan::Encrypted_PSK_Database::remove(), Botan::Encrypted_PSK_Database::set(), and Botan::Roughtime::Chain::to_string().
std::string Botan::base64_encode | ( | const std::vector< uint8_t, Alloc > & | input | ) |
Perform base64 encoding
input | some input |
Definition at line 50 of file base64.h.
References base64_encode().
std::string Botan::base64_encode | ( | const uint8_t | input[], |
size_t | input_length | ||
) |
Perform base64 encoding
input | some input |
input_length | length of input in bytes |
Definition at line 194 of file base64.cpp.
References base_encode_to_string().
size_t Botan::base64_encode_max_output | ( | size_t | input_length | ) |
Calculate the size of output buffer for base64_encode
input_length | the length of input in bytes |
Definition at line 238 of file base64.cpp.
size_t Botan::base_decode | ( | Base && | base, |
uint8_t | output[], | ||
const char | input[], | ||
size_t | input_length, | ||
size_t & | input_consumed, | ||
bool | final_inputs, | ||
bool | ignore_ws = true |
||
) |
Perform decoding using the base provided
base | object giving access to the encodings specifications |
output | an array of at least Base::decode_max_output bytes |
input | some base input |
input_length | length of input in bytes |
input_consumed | is an output parameter which says how many bytes of input were actually consumed. If less than input_length, then the range input[consumed:length] should be passed in later along with more input. |
final_inputs | true iff this is the last input, in which case padding is allowed |
ignore_ws | ignore whitespace on input; if false, throw an exception if whitespace is encountered |
Definition at line 124 of file codec_base.h.
References clear_mem().
Referenced by base32_decode(), base64_decode(), and base_decode_full().
size_t Botan::base_decode_full | ( | Base && | base, |
uint8_t | output[], | ||
const char | input[], | ||
size_t | input_length, | ||
bool | ignore_ws | ||
) |
Definition at line 189 of file codec_base.h.
References base_decode().
Referenced by base32_decode(), base64_decode(), and base_decode_to_vec().
Vector Botan::base_decode_to_vec | ( | Base && | base, |
const char | input[], | ||
size_t | input_length, | ||
bool | ignore_ws | ||
) |
Definition at line 203 of file codec_base.h.
References base_decode_full().
size_t Botan::base_encode | ( | Base && | base, |
char | output[], | ||
const uint8_t | input[], | ||
size_t | input_length, | ||
size_t & | input_consumed, | ||
bool | final_inputs | ||
) |
Perform encoding using the base provided
base | object giving access to the encodings specifications |
output | an array of at least base.encode_max_output bytes |
input | is some binary data |
input_length | length of input in bytes |
input_consumed | is an output parameter which says how many bytes of input were actually consumed. If less than input_length, then the range input[consumed:length] should be passed in later along with more input. |
final_inputs | true iff this is the last input, in which case padding chars will be applied if needed |
Definition at line 34 of file codec_base.h.
Referenced by base32_encode(), base64_encode(), and base_encode_to_string().
std::string Botan::base_encode_to_string | ( | Base && | base, |
const uint8_t | input[], | ||
size_t | input_length | ||
) |
Definition at line 86 of file codec_base.h.
References base_encode(), and BOTAN_ASSERT_EQUAL.
Referenced by base32_encode(), and base64_encode().
|
inline |
Bcrypt PBKDF compatible with OpenBSD bcrypt_pbkdf
Definition at line 71 of file bcrypt_pbkdf.h.
References salt_len.
|
inline |
Two operand addition
x | the first operand (and output) |
x_size | size of x |
y | the second operand |
y_size | size of y (must be >= x_size) |
Definition at line 280 of file mp_core.h.
References bigint_add2_nc().
Referenced by Botan::BigInt::add().
|
inline |
Two operand addition with carry out
Definition at line 227 of file mp_core.h.
References BOTAN_ASSERT, carry(), word8_add2(), and word_add().
Referenced by bigint_add2().
|
inline |
Three operand addition
Definition at line 289 of file mp_core.h.
References bigint_add3_nc().
Referenced by Botan::BigInt::add2().
|
inline |
Three operand addition with carry out
Definition at line 250 of file mp_core.h.
References bigint_add3_nc(), carry(), word8_add3(), and word_add().
Referenced by bigint_add3(), bigint_add3_nc(), Botan::BigInt::mod_add(), and redc_p521().
|
inline |
Compare x and y Return -1 if x < y Return 0 if x == y Return 1 if x > y
Definition at line 525 of file mp_core.h.
References BOTAN_DEBUG_ASSERT, Botan::CT::Mask< T >::is_equal(), Botan::CT::Mask< T >::is_lt(), Botan::CT::Mask< T >::is_zero(), and Botan::CT::unpoison().
Referenced by Botan::BigInt::add(), bigint_sub_abs(), Botan::BigInt::cmp(), and Botan::BigInt::cmp_word().
|
inline |
Definition at line 212 of file mp_core.h.
References carry(), Botan::CT::Mask< T >::expand(), and word_add().
|
inline |
Definition at line 79 of file mp_core.h.
References bigint_cnd_add().
|
inline |
Definition at line 42 of file mp_core.h.
References BOTAN_ASSERT, carry(), Botan::CT::Mask< T >::expand(), word8_add3(), and word_add().
Referenced by bigint_cnd_add(), Botan::BigInt::ct_cond_add(), redc_p192(), redc_p224(), redc_p256(), and redc_p384().
|
inline |
Definition at line 139 of file mp_core.h.
References carry(), Botan::CT::Mask< T >::select(), word8_add3(), word8_sub3(), word_add(), and word_sub().
|
inline |
Definition at line 176 of file mp_core.h.
References carry(), Botan::CT::Mask< T >::select(), word8_add3(), word8_sub3(), word_add(), and word_sub().
Referenced by bigint_mod_sub().
|
inline |
Definition at line 126 of file mp_core.h.
References bigint_cnd_sub().
|
inline |
Definition at line 88 of file mp_core.h.
References BOTAN_ASSERT, carry(), Botan::CT::Mask< T >::expand(), word8_sub3(), and word_sub().
Referenced by bigint_cnd_sub(), and redc_p521().
|
inline |
Definition at line 29 of file mp_core.h.
References b, and Botan::CT::Mask< T >::expand().
Referenced by Botan::BigInt::ct_cond_swap().
void Botan::bigint_comba_mul16 | ( | word | z[32], |
const word | x[16], | ||
const word | y[16] | ||
) |
Definition at line 804 of file mp_comba.cpp.
References word3_muladd().
Referenced by bigint_mul().
void Botan::bigint_comba_mul24 | ( | word | z[48], |
const word | x[24], | ||
const word | y[24] | ||
) |
Definition at line 1534 of file mp_comba.cpp.