From 0050617fa234c45b76ceb0676e0c0034b95a9525 Mon Sep 17 00:00:00 2001 From: Adam Kupczyk Date: Thu, 4 May 2017 15:01:01 +0200 Subject: [PATCH] radosgw: Make compilation with CryptoPP possible. Trigger compilation error when CIVETWEB changes. Signed-off-by: Adam Kupczyk --- src/rgw/rgw_crypt.cc | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/rgw/rgw_crypt.cc b/src/rgw/rgw_crypt.cc index 0d57f4da270a..ce4494cc00eb 100644 --- a/src/rgw/rgw_crypt.cc +++ b/src/rgw/rgw_crypt.cc @@ -24,6 +24,24 @@ #include #include #include +#if defined(CIVETWEB_VERSION_MAJOR) && \ + defined(CIVETWEB_VERSION_MINOR) && \ + (CIVETWEB_VERSION_MAJOR * 100) + CIVETWEB_VERSION_MINOR >= 110 +#error SSL_CTX_set_ecdh_auto patch no longer needed. Please delete. +#else +/* + * patching for https://github.com/openssl/openssl/issues/1437 + * newer versions of civetweb do not experience problems + */ +extern "C" +{ +bool SSL_CTX_set_ecdh_auto(void* dummy, int onoff) +{ + return onoff!=0; +} +} +#endif + using namespace CryptoPP; #endif -- 2.47.3