diff options
Diffstat (limited to 'openbsd-compat/sha2.h')
-rw-r--r-- | openbsd-compat/sha2.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/openbsd-compat/sha2.h b/openbsd-compat/sha2.h index 1d6aa61e9..821f2dd6c 100644 --- a/openbsd-compat/sha2.h +++ b/openbsd-compat/sha2.h | |||
@@ -41,7 +41,10 @@ | |||
41 | 41 | ||
42 | #include "includes.h" | 42 | #include "includes.h" |
43 | 43 | ||
44 | #if !defined(HAVE_SHA256_UPDATE) && !defined(HAVE_EVP_SHA256) | 44 | #include <openssl/opensslv.h> |
45 | |||
46 | #if !defined(HAVE_EVP_SHA256) && !defined(HAVE_SHA256_UPDATE) && \ | ||
47 | (OPENSSL_VERSION_NUMBER >= 0x00907000L) | ||
45 | 48 | ||
46 | /*** SHA-256/384/512 Various Length Definitions ***********************/ | 49 | /*** SHA-256/384/512 Various Length Definitions ***********************/ |
47 | #define SHA256_BLOCK_LENGTH 64 | 50 | #define SHA256_BLOCK_LENGTH 64 |
@@ -124,6 +127,7 @@ char *SHA512_Data(const u_int8_t *, size_t, char *) | |||
124 | __attribute__((__bounded__(__string__,1,2))) | 127 | __attribute__((__bounded__(__string__,1,2))) |
125 | __attribute__((__bounded__(__minbytes__,3,SHA512_DIGEST_STRING_LENGTH))); | 128 | __attribute__((__bounded__(__minbytes__,3,SHA512_DIGEST_STRING_LENGTH))); |
126 | 129 | ||
127 | #endif /* !defined(HAVE_SHA256_UPDATE) && !defined(HAVE_EVP_SHA256) */ | 130 | #endif /* !defined(HAVE_EVP_SHA256) && !defined(HAVE_SHA256_UPDATE) && \ |
131 | (OPENSSL_VERSION_NUMBER >= 0x00907000L) */ | ||
128 | 132 | ||
129 | #endif /* _SSHSHA2_H */ | 133 | #endif /* _SSHSHA2_H */ |