From 500413e393d86bcccdc5f4fc5d5a2c5ca377a70b Mon Sep 17 00:00:00 2001 From: tb Date: Tue, 25 Apr 2023 17:20:24 +0000 Subject: [PATCH] Remove the no longer used BN_MONT_CTX_init() --- lib/libcrypto/bn/bn.h | 6 +----- lib/libcrypto/bn/bn_mont.c | 11 +---------- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/lib/libcrypto/bn/bn.h b/lib/libcrypto/bn/bn.h index 9fefde20a8e..4fd795671d9 100644 --- a/lib/libcrypto/bn/bn.h +++ b/lib/libcrypto/bn/bn.h @@ -1,4 +1,4 @@ -/* $OpenBSD: bn.h,v 1.66 2023/04/25 17:13:06 tb Exp $ */ +/* $OpenBSD: bn.h,v 1.67 2023/04/25 17:20:24 tb Exp $ */ /* Copyright (C) 1995-1997 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -464,10 +464,6 @@ int BN_is_prime_fasttest_ex(const BIGNUM *p, int nchecks, BN_CTX *ctx, int do_trial_division, BN_GENCB *cb); BN_MONT_CTX *BN_MONT_CTX_new(void ); -/* Remove in next major bump. */ -#if !defined(LIBRESSL_NEXT_API) || defined(LIBRESSL_INTERNAL) -void BN_MONT_CTX_init(BN_MONT_CTX *ctx); -#endif int BN_mod_mul_montgomery(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, BN_MONT_CTX *mont, BN_CTX *ctx); int BN_to_montgomery(BIGNUM *r, const BIGNUM *a, BN_MONT_CTX *mont, diff --git a/lib/libcrypto/bn/bn_mont.c b/lib/libcrypto/bn/bn_mont.c index 26b9a6f64dd..f6ca5a34f19 100644 --- a/lib/libcrypto/bn/bn_mont.c +++ b/lib/libcrypto/bn/bn_mont.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bn_mont.c,v 1.57 2023/04/22 14:31:44 jsing Exp $ */ +/* $OpenBSD: bn_mont.c,v 1.58 2023/04/25 17:20:24 tb Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -138,15 +138,6 @@ BN_MONT_CTX_new(void) return mctx; } -void -BN_MONT_CTX_init(BN_MONT_CTX *mctx) -{ - memset(mctx, 0, sizeof(*mctx)); - - BN_init(&mctx->RR); - BN_init(&mctx->N); -} - void BN_MONT_CTX_free(BN_MONT_CTX *mctx) { -- 2.20.1