From 6be04bb370738367de4f742395c31f805f87c27e Mon Sep 17 00:00:00 2001 From: jsing Date: Sat, 15 Apr 2023 19:30:31 +0000 Subject: [PATCH] Remove sha3() function, which will not be used or exposed. --- lib/libcrypto/sha/sha3.c | 14 +------------- lib/libcrypto/sha/sha3_internal.h | 4 +--- 2 files changed, 2 insertions(+), 16 deletions(-) diff --git a/lib/libcrypto/sha/sha3.c b/lib/libcrypto/sha/sha3.c index 0ef5bf216e4..c775e57ea34 100644 --- a/lib/libcrypto/sha/sha3.c +++ b/lib/libcrypto/sha/sha3.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sha3.c,v 1.12 2023/04/15 19:29:20 jsing Exp $ */ +/* $OpenBSD: sha3.c,v 1.13 2023/04/15 19:30:31 jsing Exp $ */ /* * The MIT License (MIT) * @@ -164,18 +164,6 @@ sha3_final(void *md, sha3_ctx *c) return 1; } -void * -sha3(const void *in, size_t inlen, void *md, int mdlen) -{ - sha3_ctx sha3; - - sha3_init(&sha3, mdlen); - sha3_update(&sha3, in, inlen); - sha3_final(md, &sha3); - - return md; -} - /* SHAKE128 and SHAKE256 extensible-output functionality. */ void shake_xof(sha3_ctx *c) diff --git a/lib/libcrypto/sha/sha3_internal.h b/lib/libcrypto/sha/sha3_internal.h index 9b5b9e2b6af..7aaa0160500 100644 --- a/lib/libcrypto/sha/sha3_internal.h +++ b/lib/libcrypto/sha/sha3_internal.h @@ -1,4 +1,4 @@ -/* $OpenBSD: sha3_internal.h,v 1.10 2023/04/15 19:29:20 jsing Exp $ */ +/* $OpenBSD: sha3_internal.h,v 1.11 2023/04/15 19:30:31 jsing Exp $ */ /* * The MIT License (MIT) * @@ -67,8 +67,6 @@ int sha3_init(sha3_ctx *c, int mdlen); int sha3_update(sha3_ctx *c, const void *data, size_t len); int sha3_final(void *md, sha3_ctx *c); -void *sha3(const void *in, size_t inlen, void *md, int mdlen); - /* SHAKE128 and SHAKE256 extensible-output functions. */ #define shake128_init(c) sha3_init(c, 16) #define shake256_init(c) sha3_init(c, 32) -- 2.20.1