| Botan
    1.10.16
    | 
#include <ec_group.h>
| Public Member Functions | |
| SecureVector< byte > | DER_encode (EC_Group_Encoding form) const | 
| EC_Group (const CurveGFp &curve, const PointGFp &base_point, const BigInt &order, const BigInt &cofactor) | |
| EC_Group (const MemoryRegion< byte > &ber_encoding) | |
| EC_Group (const OID &oid) | |
| EC_Group (const std::string &pem_or_oid="") | |
| const PointGFp & | get_base_point () const | 
| const BigInt & | get_cofactor () const | 
| const CurveGFp & | get_curve () const | 
| std::string | get_oid () const | 
| const BigInt & | get_order () const | 
| bool | initialized () const | 
| bool | operator== (const EC_Group &other) const | 
| std::string | PEM_encode () const | 
Class representing an elliptic curve
Definition at line 31 of file ec_group.h.
| 
 | inline | 
Construct Domain paramers from specified parameters
| curve | elliptic curve | 
| base_point | a base point | 
| order | the order of the base point | 
| cofactor | the cofactor | 
Definition at line 42 of file ec_group.h.
References oid, and Botan::PKCS8::PEM_encode().
Referenced by EC_Group().
| Botan::EC_Group::EC_Group | ( | const MemoryRegion< byte > & | ber_encoding | ) | 
Decode a BER encoded ECC domain parameter set
| ber_encoding | the bytes of the BER encoding | 
Definition at line 51 of file ec_group.cpp.
References Botan::BER_Decoder::decode(), Botan::BER_Decoder::decode_and_check(), Botan::BER_Decoder::decode_octet_string_bigint(), EC_Group(), Botan::BER_Decoder::end_cons(), Botan::BER_Decoder::get_next_object(), Botan::NULL_TAG, Botan::OBJECT_ID, Botan::OCTET_STRING, Botan::OS2ECP(), Botan::SEQUENCE, Botan::BER_Decoder::start_cons(), Botan::BER_Object::type_tag, and Botan::BER_Decoder::verify_end().
| Botan::EC_Group::EC_Group | ( | const OID & | oid | ) | 
Create an EC domain by OID (or throw if unknown)
| oid | the OID of the EC domain to create | 
Definition at line 19 of file ec_group.cpp.
References Botan::OID::as_string(), EC_Group(), Botan::Library_State::get(), Botan::Global_State_Management::global_state(), and Botan::OIDS::lookup().
| Botan::EC_Group::EC_Group | ( | const std::string & | pem_or_oid = "" | ) | 
Create an EC domain from PEM encoding (as from PEM_encode), or from an OID name (eg "secp160r1", or "1.3.132.0.8")
| pem_or_oid | PEM-encoded data, or an OID | 
Definition at line 31 of file ec_group.cpp.
References Botan::PEM_Code::decode_check_label(), EC_Group(), and Botan::OIDS::lookup().
| SecureVector< byte > Botan::EC_Group::DER_encode | ( | EC_Group_Encoding | form | ) | const | 
Create the DER encoding of this domain
| form | of encoding to use | 
Definition at line 95 of file ec_group.cpp.
References Botan::BigInt::bytes(), Botan::EC2OSP(), Botan::EC_DOMPAR_ENC_EXPLICIT, Botan::EC_DOMPAR_ENC_IMPLICITCA, Botan::EC_DOMPAR_ENC_OID, Botan::DER_Encoder::encode(), Botan::BigInt::encode_1363(), Botan::DER_Encoder::encode_null(), Botan::DER_Encoder::end_cons(), Botan::CurveGFp::get_a(), Botan::CurveGFp::get_b(), Botan::DER_Encoder::get_contents(), get_oid(), Botan::CurveGFp::get_p(), Botan::OCTET_STRING, Botan::SEQUENCE, Botan::DER_Encoder::start_cons(), and Botan::PointGFp::UNCOMPRESSED.
Referenced by PEM_encode().
| 
 | inline | 
Return domain parameter curve
Definition at line 95 of file ec_group.h.
Referenced by Botan::EC_PrivateKey::EC_PrivateKey(), and operator==().
| 
 | inline | 
Return the cofactor
Definition at line 107 of file ec_group.h.
Referenced by operator==().
| 
 | inline | 
Return domain parameter curve
Definition at line 89 of file ec_group.h.
Referenced by operator==().
| 
 | inline | 
Return the OID of these domain parameters
Definition at line 115 of file ec_group.h.
References oid.
Referenced by DER_encode(), and Botan::EC_PublicKey::set_parameter_encoding().
| 
 | inline | 
Return the order of the base point
Definition at line 101 of file ec_group.h.
Referenced by Botan::ECDH_KA_Operation::ECDH_KA_Operation(), and operator==().
| 
 | inline | 
Definition at line 109 of file ec_group.h.
| 
 | inline | 
Definition at line 117 of file ec_group.h.
References get_base_point(), get_cofactor(), get_curve(), get_order(), and oid.
| std::string Botan::EC_Group::PEM_encode | ( | ) | const | 
Return the PEM encoding (always in explicit form)
Definition at line 131 of file ec_group.cpp.
References DER_encode(), Botan::EC_DOMPAR_ENC_EXPLICIT, and Botan::PEM_Code::encode().
 1.8.13
 1.8.13