Fix race for X509 store found by thread sanitizer
[openssl.git] / doc / man3 / EC_GROUP_copy.pod
index ee3ce27bb53de47159ea4d3febc94493b64ee009..e525fad0bf6b332260bf241c46e15f01b4eec2fd 100644 (file)
@@ -12,7 +12,8 @@ EC_GROUP_get_seed_len, EC_GROUP_set_seed, EC_GROUP_get_degree,
 EC_GROUP_check, EC_GROUP_check_named_curve,
 EC_GROUP_check_discriminant, EC_GROUP_cmp,
 EC_GROUP_get_basis_type, EC_GROUP_get_trinomial_basis,
-EC_GROUP_get_pentanomial_basis, EC_GROUP_get0_field
+EC_GROUP_get_pentanomial_basis, EC_GROUP_get0_field,
+EC_GROUP_get_field_type
 - Functions for manipulating EC_GROUP objects
 
 =head1 SYNOPSIS
@@ -42,9 +43,9 @@ EC_GROUP_get_pentanomial_basis, EC_GROUP_get0_field
  void EC_GROUP_set_point_conversion_form(EC_GROUP *group, point_conversion_form_t form);
  point_conversion_form_t EC_GROUP_get_point_conversion_form(const EC_GROUP *group);
 
- unsigned char *EC_GROUP_get0_seed(const EC_GROUP *x);
- size_t EC_GROUP_get_seed_len(const EC_GROUP *);
- size_t EC_GROUP_set_seed(EC_GROUP *, const unsigned char *, size_t len);
+ unsigned char *EC_GROUP_get0_seed(const EC_GROUP *group);
+ size_t EC_GROUP_get_seed_len(const EC_GROUP *group);
+ size_t EC_GROUP_set_seed(EC_GROUP *group, const unsigned char *, size_t len);
 
  int EC_GROUP_get_degree(const EC_GROUP *group);
 
@@ -56,12 +57,16 @@ EC_GROUP_get_pentanomial_basis, EC_GROUP_get0_field
 
  int EC_GROUP_cmp(const EC_GROUP *a, const EC_GROUP *b, BN_CTX *ctx);
 
- int EC_GROUP_get_basis_type(const EC_GROUP *);
- int EC_GROUP_get_trinomial_basis(const EC_GROUP *, unsigned int *k);
- int EC_GROUP_get_pentanomial_basis(const EC_GROUP *, unsigned int *k1,
+ int EC_GROUP_get_basis_type(const EC_GROUP *group);
+ int EC_GROUP_get_trinomial_basis(const EC_GROUP *group, unsigned int *k);
+ int EC_GROUP_get_pentanomial_basis(const EC_GROUP *group, unsigned int *k1,
                                     unsigned int *k2, unsigned int *k3);
 
-Deprecated since OpenSSL 3.0:
+ int EC_GROUP_get_field_type(const EC_GROUP *group);
+
+The following function has been deprecated since OpenSSL 3.0, and can be
+hidden entirely by defining B<OPENSSL_API_COMPAT> with a suitable version value,
+see L<openssl_user_macros(7)>:
 
  const EC_METHOD *EC_GROUP_method_of(const EC_GROUP *group);
 
@@ -124,7 +129,7 @@ point_conversion_form_t is an enum defined as follows:
 For POINT_CONVERSION_UNCOMPRESSED the point is encoded as an octet signifying the UNCOMPRESSED form has been used followed by
 the octets for x, followed by the octets for y.
 
-For any given x co-ordinate for a point on a curve it is possible to derive two possible y values. For
+For any given x coordinate for a point on a curve it is possible to derive two possible y values. For
 POINT_CONVERSION_COMPRESSED the point is encoded as an octet signifying that the COMPRESSED form has been used AND which of
 the two possible solutions for y has been used, followed by the octets for x.
 
@@ -154,9 +159,10 @@ The function EC_GROUP_check_discriminant() calculates the discriminant for the c
 For a curve defined over Fp the discriminant is given by the formula 4*a^3 + 27*b^2 whilst for F2^m curves the discriminant is
 simply b. In either case for the curve to be valid the discriminant must be non zero.
 
-The function EC_GROUP_check() performs a number of checks on a curve to verify that it is valid. Checks performed include
+The function EC_GROUP_check() behaves in the following way:
+For the OpenSSL default provider it performs a number of checks on a curve to verify that it is valid. Checks performed include
 verifying that the discriminant is non zero; that a generator has been defined; that the generator is on the curve and has
-the correct order.
+the correct order. For the OpenSSL FIPS provider it uses EC_GROUP_check_named_curve() to conform to SP800-56Ar3.
 
 The function EC_GROUP_check_named_curve() determines if the group's domain parameters match one of the built-in curves supported by the library.
 The curve name is returned as a B<NID> if it matches. If the group's domain parameters have been modified then no match will be found.
@@ -211,7 +217,7 @@ EC_GROUP_get_degree() returns the degree for B<group> or 0 if the operation is n
 
 EC_GROUP_get_field_type() returns either B<NID_X9_62_prime_field> for prime curves
 or B<NID_X9_62_characteristic_two_field> for binary curves;
-these values are defined in the obj_mac.h header file.
+these values are defined in the F<< <openssl/obj_mac.h> >> header file.
 
 EC_GROUP_check_named_curve() returns the nid of the matching named curve, otherwise it returns 0 for no match, or -1 on error.
 
@@ -229,7 +235,7 @@ EC_GROUP_set_seed() returns the length of the seed that has been set. If the sup
 
 EC_GROUP_cmp() returns 0 if the curves are equal, 1 if they are not equal, or -1 on error.
 
-EC_GROUP_get_basis_type() returns the values NID_X9_62_tpBasis or NID_X9_62_ppBasis (as defined in <openssl/obj_mac.h>) for a
+EC_GROUP_get_basis_type() returns the values NID_X9_62_tpBasis or NID_X9_62_ppBasis (as defined in F<< <openssl/obj_mac.h> >>) for a
 trinomial or pentanomial respectively. Alternatively in the event of an error a 0 is returned.
 
 =head1 SEE ALSO
@@ -241,12 +247,12 @@ L<EC_GFp_simple_method(3)>, L<d2i_ECPKParameters(3)>
 =head1 HISTORY
 
 EC_GROUP_method_of() was deprecated in OpenSSL 3.0.
-
-EC_GROUP_check_named_curve() and EC_GROUP_get_field_type() were added in OpenSSL 3.0.
+EC_GROUP_get0_field(), EC_GROUP_check_named_curve() and EC_GROUP_get_field_type() were added in OpenSSL 3.0.
+EC_GROUP_get0_order(), EC_GROUP_order_bits() and EC_GROUP_get0_cofactor() were added in OpenSSL 1.1.0.
 
 =head1 COPYRIGHT
 
-Copyright 2013-2020 The OpenSSL Project Authors. All Rights Reserved.
+Copyright 2013-2023 The OpenSSL Project Authors. All Rights Reserved.
 
 Licensed under the Apache License 2.0 (the "License").  You may not use
 this file except in compliance with the License.  You can obtain a copy