From ec67d97c6ef9a1f6dd87f9ca2611382bff7a8d30 Mon Sep 17 00:00:00 2001 From: tb Date: Mon, 10 May 2021 16:58:18 +0000 Subject: [PATCH] Expose EC_POINT_{get,set}_affine_coordinates(3) and EC_POINT_set_compressed_coordinates(3) ok jsing --- lib/libcrypto/Symbols.list | 3 +++ lib/libcrypto/ec/ec.h | 15 ++++++++------- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/lib/libcrypto/Symbols.list b/lib/libcrypto/Symbols.list index c5023001eff..c8834c5a1c4 100644 --- a/lib/libcrypto/Symbols.list +++ b/lib/libcrypto/Symbols.list @@ -1130,6 +1130,7 @@ EC_POINT_dbl EC_POINT_dup EC_POINT_free EC_POINT_get_Jprojective_coordinates_GFp +EC_POINT_get_affine_coordinates EC_POINT_get_affine_coordinates_GF2m EC_POINT_get_affine_coordinates_GFp EC_POINT_hex2point @@ -1145,8 +1146,10 @@ EC_POINT_point2bn EC_POINT_point2hex EC_POINT_point2oct EC_POINT_set_Jprojective_coordinates_GFp +EC_POINT_set_affine_coordinates EC_POINT_set_affine_coordinates_GF2m EC_POINT_set_affine_coordinates_GFp +EC_POINT_set_compressed_coordinates EC_POINT_set_compressed_coordinates_GF2m EC_POINT_set_compressed_coordinates_GFp EC_POINT_set_to_infinity diff --git a/lib/libcrypto/ec/ec.h b/lib/libcrypto/ec/ec.h index e8b00c8e23d..61b70897f9c 100644 --- a/lib/libcrypto/ec/ec.h +++ b/lib/libcrypto/ec/ec.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ec.h,v 1.23 2021/05/10 16:55:19 tb Exp $ */ +/* $OpenBSD: ec.h,v 1.24 2021/05/10 16:58:19 tb Exp $ */ /* * Originally written by Bodo Moeller for the OpenSSL project. */ @@ -453,12 +453,6 @@ const EC_METHOD *EC_POINT_method_of(const EC_POINT *point); */ int EC_POINT_set_to_infinity(const EC_GROUP *group, EC_POINT *point); -#if defined(LIBRESSL_INTERNAL) - -int EC_POINT_set_Jprojective_coordinates(const EC_GROUP *group, EC_POINT *p, - const BIGNUM *x, const BIGNUM *y, const BIGNUM *z, BN_CTX *ctx); -int EC_POINT_get_Jprojective_coordinates(const EC_GROUP *group, - const EC_POINT *p, BIGNUM *x, BIGNUM *y, BIGNUM *z, BN_CTX *ctx); int EC_POINT_set_affine_coordinates(const EC_GROUP *group, EC_POINT *p, const BIGNUM *x, const BIGNUM *y, BN_CTX *ctx); int EC_POINT_get_affine_coordinates(const EC_GROUP *group, const EC_POINT *p, @@ -466,6 +460,13 @@ int EC_POINT_get_affine_coordinates(const EC_GROUP *group, const EC_POINT *p, int EC_POINT_set_compressed_coordinates(const EC_GROUP *group, EC_POINT *p, const BIGNUM *x, int y_bit, BN_CTX *ctx); +#if defined(LIBRESSL_INTERNAL) + +int EC_POINT_set_Jprojective_coordinates(const EC_GROUP *group, EC_POINT *p, + const BIGNUM *x, const BIGNUM *y, const BIGNUM *z, BN_CTX *ctx); +int EC_POINT_get_Jprojective_coordinates(const EC_GROUP *group, + const EC_POINT *p, BIGNUM *x, BIGNUM *y, BIGNUM *z, BN_CTX *ctx); + #else /** Sets the jacobian projective coordinates of a EC_POINT over GFp -- 2.20.1