From 425a6886f99235e61faf8ea67c8f573f188eb2b2 Mon Sep 17 00:00:00 2001 From: Tim Rice Date: Wed, 15 Mar 2006 20:17:05 -0800 Subject: - (tim) [kex.c myproposal.h md-sha256.c openbsd-compat/sha2.c,h] Disable sha256 when openssl < 0.9.7. Patch from djm@. Corrections/testing by me. --- openbsd-compat/sha2.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'openbsd-compat/sha2.c') diff --git a/openbsd-compat/sha2.c b/openbsd-compat/sha2.c index 36ab60e62..cf8e0ad66 100644 --- a/openbsd-compat/sha2.c +++ b/openbsd-compat/sha2.c @@ -38,7 +38,10 @@ #include "includes.h" -#if !defined(HAVE_SHA256_UPDATE) && !defined(HAVE_EVP_SHA256) +#include + +#if !defined(HAVE_EVP_SHA256) && !defined(HAVE_SHA256_UPDATE) && \ + (OPENSSL_VERSION_NUMBER >= 0x00907000L) #include #include #include "sha2.h" @@ -875,4 +878,5 @@ SHA384_Final(u_int8_t digest[SHA384_DIGEST_LENGTH], SHA384_CTX *context) } #endif -#endif /* !defined(HAVE_SHA256_UPDATE) && !defined(HAVE_EVP_SHA256) */ +#endif /* !defined(HAVE_EVP_SHA256) && !defined(HAVE_SHA256_UPDATE) && \ + (OPENSSL_VERSION_NUMBER >= 0x00907000L) */ -- cgit v1.2.3