aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorStefan Strogin <steils@gentoo.org>2019-07-03 18:49:07 +0300
committerAndreas Schneider <asn@cryptomilk.org>2019-07-04 17:57:35 +0200
commit0d4658740b4a7f94cdbbfaa6d4d7dbc047660d4c (patch)
treec2c6b3e4457da55cdeea62d7b6b0a6885029f162 /include
parentfed31c1ca3d2e3e178ca299cb0604631b1ee4894 (diff)
downloadlibssh-0d4658740b4a7f94cdbbfaa6d4d7dbc047660d4c.tar.gz
libssh-0d4658740b4a7f94cdbbfaa6d4d7dbc047660d4c.tar.xz
libssh-0d4658740b4a7f94cdbbfaa6d4d7dbc047660d4c.zip
libcrypto: fix compilation with LibreSSL
LibreSSL does not support FIPS mode, check for FIPS_mode() in ConfigureChecks.cmake. Signed-off-by: Stefan Strogin <steils@gentoo.org> Reviewed-by: Jakub Jelen <jjelen@redhat.com>
Diffstat (limited to 'include')
-rw-r--r--include/libssh/libcrypto.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/libssh/libcrypto.h b/include/libssh/libcrypto.h
index 541912b5..fff6ff55 100644
--- a/include/libssh/libcrypto.h
+++ b/include/libssh/libcrypto.h
@@ -112,7 +112,11 @@ typedef BN_CTX* bignum_CTX;
/* Returns true if the OpenSSL is operating in FIPS mode */
+#ifdef HAVE_OPENSSL_FIPS_MODE
#define ssh_fips_mode() (FIPS_mode() != 0)
+#else
+#define ssh_fips_mode() false
+#endif
#endif /* HAVE_LIBCRYPTO */