From 32ee452496f8cf4558d645f9db908b09df919f04 Mon Sep 17 00:00:00 2001 From: Pauli Date: Fri, 21 Jun 2019 09:27:48 +1000 Subject: Remove OPENSSL_memcmp. After avoiding OPENSSL_memcmp for EC curve comparison, there are no remaining uses in the source code. The function is only defined in an internal header and thus should be safe to remove for 3.0.0. Reviewed-by: Tomas Mraz Reviewed-by: Dmitry Belyavskiy (Merged from https://github.com/openssl/openssl/pull/9207) --- crypto/ec/ec_curve.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'crypto/ec/ec_curve.c') diff --git a/crypto/ec/ec_curve.c b/crypto/ec/ec_curve.c index 6c7c9ddbc7..1ea85946d6 100644 --- a/crypto/ec/ec_curve.c +++ b/crypto/ec/ec_curve.c @@ -1,5 +1,5 @@ /* - * Copyright 2002-2018 The OpenSSL Project Authors. All Rights Reserved. + * Copyright 2002-2019 The OpenSSL Project Authors. All Rights Reserved. * Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved * * Licensed under the Apache License 2.0 (the "License"). You may not use @@ -14,7 +14,6 @@ #include #include #include "internal/nelem.h" -#include "internal/o_str.h" typedef struct { int field_type, /* either NID_X9_62_prime_field or @@ -3302,10 +3301,10 @@ int ec_curve_nid_from_params(const EC_GROUP *group) /* Check the optional seed (ignore if its not set) */ && (data->seed_len == 0 || seed_len == 0 || ((size_t)data->seed_len == seed_len - && OPENSSL_memcmp(params_seed, seed, seed_len) == 0)) + && memcmp(params_seed, seed, seed_len) == 0)) /* Check that the groups params match the built-in curve params */ - && OPENSSL_memcmp(param_bytes, params, param_len * NUM_BN_FIELDS) - == 0) { + && memcmp(param_bytes, params, param_len * NUM_BN_FIELDS) + == 0) { ret = curve.nid; goto end; } -- cgit v1.2.3