Botan 2.19.1
Crypto and TLS for C&
|
#include <pkix_types.h>
Public Member Functions | |
void | add_attribute (const std::string &type, const std::string &value) |
void | add_othername (const OID &oid, const std::string &value, ASN1_Tag type) |
AlternativeName (const std::string &email_addr="", const std::string &uri="", const std::string &dns="", const std::string &ip_address="") | |
std::vector< uint8_t > | BER_encode () const |
std::multimap< std::string, std::string > | contents () const |
void | decode_from (BER_Decoder &) override |
X509_DN | dn () const |
void | encode_into (DER_Encoder &) const override |
std::vector< std::string > | get_attribute (const std::string &attr) const |
const std::multimap< std::string, std::string > & | get_attributes () const |
std::string | get_first_attribute (const std::string &attr) const |
const std::multimap< OID, ASN1_String > & | get_othernames () const |
bool | has_field (const std::string &attr) const |
bool | has_items () const |
Alternative Name
Definition at line 123 of file pkix_types.h.
Botan::AlternativeName::AlternativeName | ( | const std::string & | email_addr = "" , |
const std::string & | uri = "" , |
||
const std::string & | dns = "" , |
||
const std::string & | ip_address = "" |
||
) |
Definition at line 24 of file asn1_alt_name.cpp.
References add_attribute().
void Botan::AlternativeName::add_attribute | ( | const std::string & | type, |
const std::string & | value | ||
) |
Definition at line 38 of file asn1_alt_name.cpp.
References Botan::multimap_insert(), and type.
Referenced by AlternativeName(), Botan::create_alt_name(), and decode_from().
void Botan::AlternativeName::add_othername | ( | const OID & | oid, |
const std::string & | value, | ||
ASN1_Tag | type | ||
) |
Definition at line 55 of file asn1_alt_name.cpp.
References Botan::multimap_insert(), and type.
Referenced by decode_from().
|
inherited |
Return the encoding of this object. This is a convenience method when just one object needs to be serialized. Use DER_Encoder for complicated encodings.
Definition at line 16 of file asn1_obj.cpp.
References Botan::ASN1_Object::encode_into().
Referenced by Botan::PSSR::config_for_x509(), Botan::Certificate_Store_In_SQL::find_all_certs(), Botan::Certificate_Store_In_SQL::find_cert(), Botan::X509_Certificate::fingerprint(), Botan::Certificate_Store_In_SQL::insert_cert(), Botan::X509_Object::PEM_encode(), and Botan::Certificate_Store_In_SQL::revoke_cert().
std::multimap< std::string, std::string > Botan::AlternativeName::contents | ( | ) | const |
Definition at line 66 of file asn1_alt_name.cpp.
References Botan::multimap_insert().
|
overridevirtual |
Decode whatever this object is from from
from | the BER_Decoder that will be read from |
Implements Botan::ASN1_Object.
Definition at line 195 of file asn1_alt_name.cpp.
References add_attribute(), add_othername(), Botan::BER_Object::bits(), Botan::CONSTRUCTED, Botan::CONTEXT_SPECIFIC, Botan::BER_Decoder::decode(), dn(), Botan::BER_Object::get_class(), Botan::BER_Decoder::get_next_object(), Botan::ipv4_to_string(), Botan::BER_Object::is_a(), Botan::ASN1_String::is_string_type(), Botan::BER_Object::length(), Botan::load_be< uint32_t >(), Botan::BER_Decoder::more_items(), Botan::SEQUENCE, Botan::BER_Decoder::start_cons(), Botan::ASN1::to_string(), Botan::BER_Object::type(), Botan::UNIVERSAL, and Botan::BER_Decoder::verify_end().
X509_DN Botan::AlternativeName::dn | ( | ) | const |
Definition at line 107 of file asn1_alt_name.cpp.
References dn().
Referenced by decode_from(), dn(), and Botan::GeneralName::matches().
|
overridevirtual |
Encode whatever this object is into to
to | the DER_Encoder that will be written to |
Implements Botan::ASN1_Object.
Definition at line 169 of file asn1_alt_name.cpp.
References Botan::DER_Encoder::encode(), Botan::DER_Encoder::end_cons(), Botan::DER_Encoder::end_explicit(), Botan::SEQUENCE, Botan::DER_Encoder::start_cons(), and Botan::DER_Encoder::start_explicit().
std::vector< std::string > Botan::AlternativeName::get_attribute | ( | const std::string & | attr | ) | const |
Definition at line 98 of file asn1_alt_name.cpp.
Referenced by Botan::X509_Certificate::issuer_info(), Botan::GeneralName::matches(), and Botan::X509_Certificate::subject_info().
|
inline |
Definition at line 139 of file pkix_types.h.
std::string Botan::AlternativeName::get_first_attribute | ( | const std::string & | attr | ) | const |
Definition at line 89 of file asn1_alt_name.cpp.
|
inline |
Definition at line 144 of file pkix_types.h.
bool Botan::AlternativeName::has_field | ( | const std::string & | attr | ) | const |
Definition at line 83 of file asn1_alt_name.cpp.
bool Botan::AlternativeName::has_items | ( | ) | const |
Definition at line 124 of file asn1_alt_name.cpp.