Botan 3.6.1
Crypto and TLS for C&
|
#include <tls_signature_scheme.h>
Public Types | |
enum | Code : uint16_t { NONE = 0x0000 , RSA_PKCS1_SHA1 = 0x0201 , RSA_PKCS1_SHA256 = 0x0401 , RSA_PKCS1_SHA384 = 0x0501 , RSA_PKCS1_SHA512 = 0x0601 , ECDSA_SHA1 = 0x0203 , ECDSA_SHA256 = 0x0403 , ECDSA_SHA384 = 0x0503 , ECDSA_SHA512 = 0x0603 , RSA_PSS_SHA256 = 0x0804 , RSA_PSS_SHA384 = 0x0805 , RSA_PSS_SHA512 = 0x0806 , EDDSA_25519 = 0x0807 , EDDSA_448 = 0x0808 } |
Public Member Functions | |
AlgorithmIdentifier | algorithm_identifier () const noexcept |
std::string | algorithm_name () const noexcept |
std::optional< Signature_Format > | format () const noexcept |
std::string | hash_function_name () const noexcept |
bool | is_available () const noexcept |
bool | is_compatible_with (const Protocol_Version &protocol_version) const noexcept |
bool | is_set () const noexcept |
bool | is_suitable_for (const Private_Key &private_key) const noexcept |
AlgorithmIdentifier | key_algorithm_identifier () const noexcept |
bool | operator!= (const Signature_Scheme &rhs) const |
bool | operator== (const Signature_Scheme &rhs) const |
std::string | padding_string () const noexcept |
Signature_Scheme () | |
Signature_Scheme (Signature_Scheme::Code wire_code) | |
Signature_Scheme (uint16_t wire_code) | |
std::string | to_string () const noexcept |
Signature_Scheme::Code | wire_code () const noexcept |
Static Public Member Functions | |
static const std::vector< Signature_Scheme > & | all_available_schemes () |
Definition at line 23 of file tls_signature_scheme.h.
enum Botan::TLS::Signature_Scheme::Code : uint16_t |
Matches with wire encoding
Note that this is intentionally left as a bare enum. It emulates the Botan 2 API where Signature_Scheme
was an enum class with associated free-standing functions. Leaving it as a bare enum resembles the legacy user-facing API.
Enumerator | |
---|---|
NONE | |
RSA_PKCS1_SHA1 | |
RSA_PKCS1_SHA256 | |
RSA_PKCS1_SHA384 | |
RSA_PKCS1_SHA512 | |
ECDSA_SHA1 | |
ECDSA_SHA256 | |
ECDSA_SHA384 | |
ECDSA_SHA512 | |
RSA_PSS_SHA256 | |
RSA_PSS_SHA384 | |
RSA_PSS_SHA512 | |
EDDSA_25519 | |
EDDSA_448 |
Definition at line 32 of file tls_signature_scheme.h.
Botan::TLS::Signature_Scheme::Signature_Scheme | ( | ) |
Construct an uninitialized / invalid scheme
Definition at line 51 of file tls_signature_scheme.cpp.
Botan::TLS::Signature_Scheme::Signature_Scheme | ( | uint16_t | wire_code | ) |
Definition at line 53 of file tls_signature_scheme.cpp.
Botan::TLS::Signature_Scheme::Signature_Scheme | ( | Signature_Scheme::Code | wire_code | ) |
Definition at line 55 of file tls_signature_scheme.cpp.
|
noexcept |
Definition at line 226 of file tls_signature_scheme.cpp.
References ECDSA_SHA1, ECDSA_SHA256, ECDSA_SHA384, ECDSA_SHA512, Botan::OID::from_string(), RSA_PKCS1_SHA1, RSA_PKCS1_SHA256, RSA_PKCS1_SHA384, RSA_PKCS1_SHA512, RSA_PSS_SHA256, RSA_PSS_SHA384, RSA_PSS_SHA512, Botan::AlgorithmIdentifier::USE_EMPTY_PARAM, and Botan::AlgorithmIdentifier::USE_NULL_PARAM.
|
noexcept |
Definition at line 169 of file tls_signature_scheme.cpp.
References ECDSA_SHA1, ECDSA_SHA256, ECDSA_SHA384, ECDSA_SHA512, EDDSA_25519, EDDSA_448, RSA_PKCS1_SHA1, RSA_PKCS1_SHA256, RSA_PKCS1_SHA384, RSA_PKCS1_SHA512, RSA_PSS_SHA256, RSA_PSS_SHA384, and RSA_PSS_SHA512.
Referenced by Botan::TLS::Handshake_State::parse_sig_format().
|
static |
Definition at line 21 of file tls_signature_scheme.cpp.
References ECDSA_SHA256, ECDSA_SHA384, ECDSA_SHA512, RSA_PKCS1_SHA256, RSA_PKCS1_SHA384, RSA_PKCS1_SHA512, RSA_PSS_SHA256, RSA_PSS_SHA384, and RSA_PSS_SHA512.
Referenced by Botan::TLS::Policy::allowed_signature_schemes(), and is_available().
|
noexcept |
Definition at line 259 of file tls_signature_scheme.cpp.
References Botan::DerSequence, ECDSA_SHA1, ECDSA_SHA256, ECDSA_SHA384, ECDSA_SHA512, EDDSA_25519, EDDSA_448, RSA_PKCS1_SHA1, RSA_PKCS1_SHA256, RSA_PKCS1_SHA384, RSA_PKCS1_SHA512, RSA_PSS_SHA256, RSA_PSS_SHA384, RSA_PSS_SHA512, and Botan::Standard.
Referenced by Botan::TLS::Certificate_Verify_13::Certificate_Verify_13(), Botan::TLS::Handshake_State::choose_sig_format(), Botan::TLS::Handshake_State::parse_sig_format(), and Botan::TLS::Certificate_Verify_13::verify().
|
noexcept |
Definition at line 102 of file tls_signature_scheme.cpp.
References ECDSA_SHA1, ECDSA_SHA256, ECDSA_SHA384, ECDSA_SHA512, EDDSA_25519, EDDSA_448, RSA_PKCS1_SHA1, RSA_PKCS1_SHA256, RSA_PKCS1_SHA384, RSA_PKCS1_SHA512, RSA_PSS_SHA256, RSA_PSS_SHA384, and RSA_PSS_SHA512.
Referenced by Botan::TLS::Handshake_State::choose_sig_format(), and Botan::TLS::Handshake_State::parse_sig_format().
|
noexcept |
Definition at line 57 of file tls_signature_scheme.cpp.
References all_available_schemes(), and Botan::value_exists().
Referenced by Botan::TLS::Certificate_Verify_13::Certificate_Verify_13(), Botan::TLS::Certificate_Verify_13::Certificate_Verify_13(), Botan::TLS::Handshake_State::parse_sig_format(), and Botan::TLS::Certificate_Verify_13::verify().
|
noexcept |
Definition at line 283 of file tls_signature_scheme.cpp.
Referenced by Botan::TLS::Certificate_Verify_13::Certificate_Verify_13(), Botan::TLS::Certificate_Verify_13::Certificate_Verify_13(), and Botan::TLS::Handshake_State::parse_sig_format().
|
noexcept |
NONE
Definition at line 61 of file tls_signature_scheme.cpp.
References NONE.
Referenced by Botan::TLS::Certificate_Verify::Certificate_Verify(), and Botan::TLS::Certificate_Verify::serialize().
|
noexcept |
Definition at line 306 of file tls_signature_scheme.cpp.
|
noexcept |
Definition at line 197 of file tls_signature_scheme.cpp.
References Botan::EC_Group::DER_encode(), ECDSA_SHA256, ECDSA_SHA384, ECDSA_SHA512, EDDSA_25519, EDDSA_448, Botan::EC_Group::from_name(), RSA_PKCS1_SHA1, RSA_PKCS1_SHA256, RSA_PKCS1_SHA384, RSA_PKCS1_SHA512, RSA_PSS_SHA256, RSA_PSS_SHA384, RSA_PSS_SHA512, Botan::AlgorithmIdentifier::USE_EMPTY_PARAM, and Botan::AlgorithmIdentifier::USE_NULL_PARAM.
Referenced by Botan::TLS::Certificate_Verify_13::verify().
|
inline |
Definition at line 93 of file tls_signature_scheme.h.
|
inline |
Definition at line 91 of file tls_signature_scheme.h.
|
noexcept |
Definition at line 132 of file tls_signature_scheme.cpp.
References ECDSA_SHA1, ECDSA_SHA256, ECDSA_SHA384, ECDSA_SHA512, EDDSA_25519, EDDSA_448, RSA_PKCS1_SHA1, RSA_PKCS1_SHA256, RSA_PKCS1_SHA384, RSA_PKCS1_SHA512, RSA_PSS_SHA256, RSA_PSS_SHA384, and RSA_PSS_SHA512.
Referenced by Botan::TLS::Certificate_Verify_13::Certificate_Verify_13(), Botan::TLS::Handshake_State::choose_sig_format(), Botan::TLS::Handshake_State::parse_sig_format(), and Botan::TLS::Certificate_Verify_13::verify().
|
noexcept |
Definition at line 65 of file tls_signature_scheme.cpp.
References ECDSA_SHA1, ECDSA_SHA256, ECDSA_SHA384, ECDSA_SHA512, EDDSA_25519, EDDSA_448, RSA_PKCS1_SHA1, RSA_PKCS1_SHA256, RSA_PKCS1_SHA384, RSA_PKCS1_SHA512, RSA_PSS_SHA256, RSA_PSS_SHA384, and RSA_PSS_SHA512.
|
inlinenoexcept |
Definition at line 68 of file tls_signature_scheme.h.
Referenced by Botan::TLS::Certificate_Verify::serialize().