summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/man/EC_GFp_simple_method.3
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/man/EC_GFp_simple_method.3')
-rw-r--r--src/lib/libcrypto/man/EC_GFp_simple_method.3108
1 files changed, 108 insertions, 0 deletions
diff --git a/src/lib/libcrypto/man/EC_GFp_simple_method.3 b/src/lib/libcrypto/man/EC_GFp_simple_method.3
new file mode 100644
index 0000000000..8f401e85c8
--- /dev/null
+++ b/src/lib/libcrypto/man/EC_GFp_simple_method.3
@@ -0,0 +1,108 @@
1.Dd $Mdocdate: November 2 2016 $
2.Dt EC_GFP_SIMPLE_METHOD 3
3.Os
4.Sh NAME
5.Nm EC_GFp_simple_method ,
6.Nm EC_GFp_mont_method ,
7.Nm EC_GFp_nist_method ,
8.Nm EC_GFp_nistp224_method ,
9.Nm EC_GFp_nistp256_method ,
10.Nm EC_GFp_nistp521_method ,
11.Nm EC_GF2m_simple_method ,
12.Nm EC_METHOD_get_field_type
13.Nd obtain EC_METHOD objects
14.Sh SYNOPSIS
15.In openssl/ec.h
16.Ft const EC_METHOD *
17.Fn EC_GFp_simple_method void
18.Ft const EC_METHOD *
19.Fn EC_GFp_mont_method void
20.Ft const EC_METHOD *
21.Fn EC_GFp_nist_method void
22.Ft const EC_METHOD *
23.Fn EC_GFp_nistp224_method void
24.Ft const EC_METHOD *
25.Fn EC_GFp_nistp256_method void
26.Ft const EC_METHOD *
27.Fn EC_GFp_nistp521_method void
28.Ft const EC_METHOD *
29.Fn EC_GF2m_simple_method void
30.Ft int
31.Fo EC_METHOD_get_field_type
32.Fa "const EC_METHOD *meth"
33.Fc
34.Sh DESCRIPTION
35The elliptic curve library provides a number of different
36implementations through a single common interface.
37When constructing a curve using
38.Xr EC_GROUP_new 3 ,
39an implementation method must be provided.
40The functions described here all return a const pointer to an
41.Sy EC_METHOD
42structure that can be passed to
43.Xr EC_GROUP_new .
44It is important that the correct implementation type for the form
45of curve selected is used.
46.Pp
47For F2^m curves there is only one implementation choice,
48.Fn EC_GF2_simple_method .
49.Pp
50For Fp curves the lowest common denominator implementation is the
51.Fn EC_GFp_simple_method
52implementation.
53All other implementations are based on this one.
54.Fn EC_GFp_mont_method
55adds the use of montgomery multiplication (see
56.Xr BN_mod_mul_montgomery 3 ) .
57.Fn EC_GFp_nist_method
58offers an implementation optimised for use with NIST recommended
59curves.
60NIST curves are available through
61.Xr EC_GROUP_new_by_curve_name 3 .
62.Pp
63The functions
64.Fn EC_GFp_nistp224_method ,
65.Fn EC_GFp_nistp256_method ,
66and
67.Fn EC_GFp_nistp521_method
68offer 64 bit optimised implementations for the NIST P224, P256 and
69P521 curves respectively.
70Note, however, that these implementations are not available on all
71platforms.
72.Pp
73.Fn EC_METHOD_get_field_type
74identifies what type of field the
75.Vt EC_METHOD
76structure supports, which will be either F2^m or Fp.
77If the field type is Fp, then the value
78.Dv NID_X9_62_prime_field
79is returned.
80If the field type is F2^m, then the value
81.Dv NID_X9_62_characteristic_two_field
82is returned.
83These values are defined in the
84.In openssl/obj_mac.h
85header file.
86.Sh RETURN VALUES
87All
88.Fn EC_GFp*
89functions and
90.Fn EC_GF2m_simple_method
91always return a const pointer to an
92.Vt EC_METHOD
93structure.
94.Pp
95.Fn EC_METHOD_get_field_type
96returns an integer that identifies the type of field the
97.Vt EC_METHOD
98structure supports.
99.Sh SEE ALSO
100.Xr BN_mod_mul_montgomery 3 ,
101.Xr crypto 3 ,
102.Xr d2i_ECPKParameters 3 ,
103.Xr ec 3 ,
104.Xr EC_GROUP_copy 3 ,
105.Xr EC_GROUP_new 3 ,
106.Xr EC_KEY_new 3 ,
107.Xr EC_POINT_add 3 ,
108.Xr EC_POINT_new 3