From 07ca277790942f778ce63607bfb364dde82b3b28 Mon Sep 17 00:00:00 2001 From: tb <> Date: Wed, 6 Nov 2024 04:18:42 +0000 Subject: Toss tedu's cleanse into crypto_memory.c --- src/lib/libcrypto/crypto_memory.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/lib/libcrypto/crypto_memory.c') diff --git a/src/lib/libcrypto/crypto_memory.c b/src/lib/libcrypto/crypto_memory.c index b009f7eb4a..773927b831 100644 --- a/src/lib/libcrypto/crypto_memory.c +++ b/src/lib/libcrypto/crypto_memory.c @@ -1,4 +1,4 @@ -/* $OpenBSD: crypto_memory.c,v 1.2 2024/11/06 04:10:35 tb Exp $ */ +/* $OpenBSD: crypto_memory.c,v 1.3 2024/11/06 04:18:42 tb Exp $ */ /* * Copyright (c) 2014 Bob Beck * @@ -21,6 +21,13 @@ #include +void +OPENSSL_cleanse(void *ptr, size_t len) +{ + explicit_bzero(ptr, len); +} +LCRYPTO_ALIAS(OPENSSL_cleanse); + int CRYPTO_set_mem_functions(void *(*m)(size_t), void *(*r)(void *, size_t), void (*f)(void *)) -- cgit v1.2.3-55-g6feb