Elliptic Curve domain parameters.
More...
#include <c4e_ec.h>
Detailed Description
Elliptic Curve domain parameters.
- Note:
- All elements must be normalized, for example by by using functions c4e_elem_norm() or c4e_elem_os2e().
- Bibliography:
- Polk, W., Housley, R. and L. Bassham: Algorithms and Identifiers for the Internet X.509 Public Key Infrastructure Certificate and Certificate Revocation List (CRL) Profile. RFC 3279, IETF, April 2002.
- Bibliography:
- Standard Specifications For Public-Key Cryptography. Std 1363-2000, IEEE, 2000.
- See also:
- C4eEcPoint, C4eElement, C4E_ELEM_ASGN_MEM()
Definition at line 60 of file c4e_ec.h.
Field Documentation
Domain parameter a of elliptic curve E.
Definition at line 94 of file c4e_ec.h.
Domain parameter b of elliptic curve E.
Definition at line 99 of file c4e_ec.h.
Order of base point C4eEcDomain::g, a prime number. The order of elliptic curve E can be calculated by . The length of G in q.len also determines the length of an ECDSA signature, which is: 2U * q.len.
- Note:
- For nearly all well-known elliptic curves q.len is less than or equal to m.len, especially when the Hasse interval is small (see C4E_EC_FIELD_BITS_MAX()). But for special (very uncommon/rare) curves q.len respective q.val.size might be greater than m.len respective m.val.size. Macros C4E_EC_FIELD_BYTES_MAX() and C4E_EC_FIELD_DIGITS_MAX() reflect this situation (for this kind of elliptic curves).
-
The number of digits needed by q.val can be calculated by: which is the preferred method, or by:
- Attention:
- Member q.val sometimes is modified (temporary) when using functions, which deal with modular reduction, for example ECDSA. Therefore it must be writable and mutual exclusive accessible in most situations.
- See also:
- C4E_EC_FIELD_DIGITS_MAX()
Definition at line 130 of file c4e_ec.h.
Cofactor: order of the elliptic curve E (number of points on E) divided by the order of base point G (), which is a big number less than #E.
- Note:
- This element is only used by functions c4e_ecc2n_dh() and c4e_eccp_dh(), when performing ECDH with cofactor multiplication (ECDHC). If ECDHC should not be used (or ECDH at all is not used) then you are allowed to set it invalid, using macro C4E_ELEM_SET_ZERO(). There is no need to assign memory to h.digits in this case.
Definition at line 156 of file c4e_ec.h.
The documentation for this struct was generated from the following file: