From f59a5e932baaa204327818534b8c93267c20bed0 Mon Sep 17 00:00:00 2001 From: jsing <> Date: Wed, 8 Mar 2023 05:45:31 +0000 Subject: Always clear EC groups and points on free. Rather than sometimes clearing, turn the free functions into ones that always clear (as we've done elsewhere). Turn the EC_GROUP_clear_free() and EC_POINT_clear_free() functions into wrappers that call the *_free() version. Do similar for the EC_METHOD implementations, removing the group_clear_finish() and point_clear_finish() hooks in the process. ok tb@ --- src/lib/libcrypto/ec/ecp_nist.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/lib/libcrypto/ec/ecp_nist.c') diff --git a/src/lib/libcrypto/ec/ecp_nist.c b/src/lib/libcrypto/ec/ecp_nist.c index e3c13f7c65..b8fb5dc90f 100644 --- a/src/lib/libcrypto/ec/ecp_nist.c +++ b/src/lib/libcrypto/ec/ecp_nist.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ecp_nist.c,v 1.23 2023/03/08 04:50:27 jsing Exp $ */ +/* $OpenBSD: ecp_nist.c,v 1.24 2023/03/08 05:45:31 jsing Exp $ */ /* * Written by Nils Larsch for the OpenSSL project. */ @@ -171,7 +171,6 @@ static const EC_METHOD ec_GFp_nist_method = { .field_type = NID_X9_62_prime_field, .group_init = ec_GFp_simple_group_init, .group_finish = ec_GFp_simple_group_finish, - .group_clear_finish = ec_GFp_simple_group_clear_finish, .group_copy = ec_GFp_nist_group_copy, .group_set_curve = ec_GFp_nist_group_set_curve, .group_get_curve = ec_GFp_simple_group_get_curve, @@ -180,7 +179,6 @@ static const EC_METHOD ec_GFp_nist_method = { .group_check_discriminant = ec_GFp_simple_group_check_discriminant, .point_init = ec_GFp_simple_point_init, .point_finish = ec_GFp_simple_point_finish, - .point_clear_finish = ec_GFp_simple_point_clear_finish, .point_copy = ec_GFp_simple_point_copy, .point_set_to_infinity = ec_GFp_simple_point_set_to_infinity, .point_set_Jprojective_coordinates = -- cgit v1.2.3-55-g6feb