Botan 3.0.0-rc1
Crypto and TLS for C&
|
#include <curve_gfp.h>
Public Member Functions | |
bool | a_is_minus_3 () const |
bool | a_is_zero () const |
CurveGFp ()=default | |
CurveGFp (const BigInt &p, const BigInt &a, const BigInt &b) | |
CurveGFp (const CurveGFp &)=default | |
void | from_rep (BigInt &x, secure_vector< word > &ws) const |
BigInt | from_rep_to_tmp (const BigInt &x, secure_vector< word > &ws) const |
const BigInt & | get_1_rep () const |
const BigInt & | get_a () const |
const BigInt & | get_a_rep () const |
const BigInt & | get_b () const |
const BigInt & | get_b_rep () const |
const BigInt & | get_p () const |
size_t | get_p_words () const |
size_t | get_ws_size () const |
BigInt | invert_element (const BigInt &x, secure_vector< word > &ws) const |
bool | is_one (const BigInt &x) const |
void | mul (BigInt &z, const BigInt &x, const BigInt &y, secure_vector< word > &ws) const |
void | mul (BigInt &z, const word x_w[], size_t x_size, const BigInt &y, secure_vector< word > &ws) const |
BigInt | mul (const BigInt &x, const BigInt &y, secure_vector< word > &ws) const |
BigInt | mul_to_tmp (const BigInt &x, const BigInt &y, secure_vector< word > &ws) const |
CurveGFp & | operator= (const CurveGFp &)=default |
bool | operator== (const CurveGFp &other) const |
void | sqr (BigInt &z, const BigInt &x, secure_vector< word > &ws) const |
void | sqr (BigInt &z, const word x_w[], size_t x_size, secure_vector< word > &ws) const |
BigInt | sqr (const BigInt &x, secure_vector< word > &ws) const |
BigInt | sqr_to_tmp (const BigInt &x, secure_vector< word > &ws) const |
void | swap (CurveGFp &other) |
void | to_rep (BigInt &x, secure_vector< word > &ws) const |
This class represents an elliptic curve over GF(p)
There should not be any reason for applications to use this type. If you need EC primitives use the interfaces EC_Group and EC_Point
It is likely this class will be removed entirely in a future major release.
Definition at line 96 of file curve_gfp.h.
|
default |
Create an uninitialized CurveGFp
Construct the elliptic curve E: y^2 = x^3 + ax + b over GF(p)
p | prime number of the field |
a | first coefficient |
b | second coefficient |
Definition at line 111 of file curve_gfp.h.
|
default |
|
inline |
Definition at line 146 of file curve_gfp.h.
Referenced by Botan::EC_Point::mult2().
|
inline |
Definition at line 147 of file curve_gfp.h.
Referenced by Botan::EC_Point::mult2().
|
inline |
Definition at line 161 of file curve_gfp.h.
Referenced by Botan::EC_Point::get_affine_x(), and Botan::EC_Point::get_affine_y().
|
inline |
Definition at line 166 of file curve_gfp.h.
Referenced by Botan::EC_Point::get_affine_x(), Botan::EC_Point::get_affine_y(), and Botan::EC_Point::on_the_curve().
|
inline |
Definition at line 144 of file curve_gfp.h.
Referenced by Botan::EC_Point::add(), Botan::EC_Point::add_affine(), Botan::EC_Point::force_affine(), and Botan::EC_Point::force_all_affine().
|
inline |
Definition at line 123 of file curve_gfp.h.
Referenced by operator==(), and Botan::OS2ECP().
|
inline |
Definition at line 140 of file curve_gfp.h.
Referenced by Botan::EC_Point::mult2(), and Botan::EC_Point::on_the_curve().
|
inline |
Definition at line 128 of file curve_gfp.h.
Referenced by operator==(), and Botan::OS2ECP().
|
inline |
Definition at line 142 of file curve_gfp.h.
Referenced by Botan::EC_Point::on_the_curve().
|
inline |
Get prime modulus of the field of the curve
Definition at line 134 of file curve_gfp.h.
Referenced by Botan::EC_Point::add(), Botan::EC_Point::add_affine(), Botan::EC_Point::EC_Point(), Botan::EC_Point_Base_Point_Precompute::EC_Point_Base_Point_Precompute(), Botan::EC_Point_Var_Point_Precompute::EC_Point_Var_Point_Precompute(), Botan::EC_Point::encode(), Botan::EC_Point::mult2(), operator==(), Botan::OS2ECP(), and Botan::EC_Point::randomize_repr().
|
inline |
Definition at line 136 of file curve_gfp.h.
|
inline |
Definition at line 138 of file curve_gfp.h.
Referenced by Botan::EC_Point::add(), Botan::EC_Point::add_affine(), Botan::EC_Point::EC_Point(), Botan::EC_Point::force_all_affine(), Botan::EC_Point::mult2(), and Botan::EC_Point::randomize_repr().
|
inline |
Definition at line 151 of file curve_gfp.h.
Referenced by Botan::EC_Point::force_affine(), Botan::EC_Point::force_all_affine(), Botan::EC_Point::get_affine_x(), and Botan::EC_Point::get_affine_y().
|
inline |
Definition at line 149 of file curve_gfp.h.
Referenced by Botan::EC_Point::is_affine().
|
inline |
Definition at line 175 of file curve_gfp.h.
References y.
Referenced by Botan::EC_Point::add(), Botan::EC_Point::add_affine(), Botan::EC_Point_Var_Point_Precompute::EC_Point_Var_Point_Precompute(), Botan::EC_Point::force_all_affine(), Botan::EC_Point::get_affine_x(), Botan::EC_Point::get_affine_y(), and Botan::EC_Point::mult2().
|
inline |
Definition at line 180 of file curve_gfp.h.
References y.
|
inline |
Definition at line 196 of file curve_gfp.h.
References y.
|
inline |
Definition at line 206 of file curve_gfp.h.
References y.
Referenced by Botan::EC_Point::force_affine(), Botan::EC_Point::force_all_affine(), Botan::EC_Point::get_affine_y(), Botan::EC_Point::on_the_curve(), and Botan::EC_Point::randomize_repr().
|
inline |
Equality operator
other | a curve |
Definition at line 230 of file curve_gfp.h.
|
inline |
Definition at line 186 of file curve_gfp.h.
Referenced by Botan::EC_Point::add(), Botan::EC_Point::add_affine(), Botan::EC_Point_Var_Point_Precompute::EC_Point_Var_Point_Precompute(), Botan::EC_Point::force_all_affine(), and Botan::EC_Point::mult2().
|
inline |
Definition at line 191 of file curve_gfp.h.
|
inline |
Definition at line 201 of file curve_gfp.h.
|
inline |
Definition at line 213 of file curve_gfp.h.
Referenced by Botan::EC_Point::force_affine(), Botan::EC_Point::get_affine_x(), Botan::EC_Point::get_affine_y(), Botan::EC_Point::on_the_curve(), and Botan::EC_Point::randomize_repr().
|
inline |
Definition at line 220 of file curve_gfp.h.
Referenced by Botan::EC_Point::swap().
|
inline |
Definition at line 156 of file curve_gfp.h.
Referenced by Botan::EC_Point::EC_Point().