From eb765cd4a2b07da3fc92af29a4762d2c91e71441 Mon Sep 17 00:00:00 2001 From: tb <> Date: Tue, 5 Nov 2024 11:05:01 +0000 Subject: Move OPENSSL_cleanse() to crypto_legacy() The correct spelling is explicit_bzero() and it doesn't need its own file. discussed with jsing --- src/lib/libcrypto/crypto_legacy.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/lib/libcrypto/crypto_legacy.c') diff --git a/src/lib/libcrypto/crypto_legacy.c b/src/lib/libcrypto/crypto_legacy.c index 65ca9b5f9a..9e3ba4f3ed 100644 --- a/src/lib/libcrypto/crypto_legacy.c +++ b/src/lib/libcrypto/crypto_legacy.c @@ -1,4 +1,4 @@ -/* $OpenBSD: crypto_legacy.c,v 1.2 2024/11/05 11:02:58 tb Exp $ */ +/* $OpenBSD: crypto_legacy.c,v 1.3 2024/11/05 11:05:01 tb Exp $ */ /* ==================================================================== * Copyright (c) 1998-2006 The OpenSSL Project. All rights reserved. * @@ -356,6 +356,13 @@ OpenSSLDie(const char *file, int line, const char *assertion) } LCRYPTO_ALIAS(OpenSSLDie); +void +OPENSSL_cleanse(void *ptr, size_t len) +{ + explicit_bzero(ptr, len); +} +LCRYPTO_ALIAS(OPENSSL_cleanse); + int CRYPTO_memcmp(const void *in_a, const void *in_b, size_t len) { -- cgit v1.2.3-55-g6feb