The OpenSSL developers suggest that anyone wishing to continue using
low-level functions may either live with the warnings, silence them,
or switch to high level functions.
As high level functions do their own memory allocation, switching to
them may lead to performance regressions.
We do not wish to have deprecation warnings filling up our compiler
outputs when searching for other messages.
So silencing the warnings, at least for now, seems the least bad option.
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit
d5e1fdfc3cfd15b59e0e8fe2408c995b0cc8c0e7)
#include "common/debug.h"
#include <errno.h>
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+
using std::ostringstream;
using std::string;
using ceph::bufferptr;
using ceph::Formatter;
+
// use getentropy() if available. it uses the same source of randomness
// as /dev/urandom without the filesystem overhead
#ifdef HAVE_GETENTROPY
return NULL;
}
}
+
+#pragma clang diagnostic pop
+#pragma GCC diagnostic pop
# include <openssl/err.h>
#endif /* OPENSSL_VERSION_NUMBER < 0x10100000L */
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+
namespace TOPNSPC::crypto::ssl {
#if OPENSSL_VERSION_NUMBER < 0x10100000L
}
}
+
+#pragma clang diagnostic pop
+#pragma GCC diagnostic pop
#include "include/ceph_assert.h"
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+
extern "C" {
const EVP_MD *EVP_md5(void);
const EVP_MD *EVP_sha1(void);
}
}
+#pragma clang diagnostic pop
+#pragma GCC diagnostic pop
+
#endif
}
OPENSSL_load_builtin_modules();
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
ENGINE_load_builtin_engines();
+#pragma clang diagnostic pop
+#pragma GCC diagnostic pop
if (CONF_modules_load(
conf, nullptr,
#include "rgw_rest.h"
#include "rgw_sts.h"
#include "rgw_web_idp.h"
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
#include "jwt-cpp/jwt.h"
+#pragma clang diagnostic pop
+#pragma GCC diagnostic pop
#include "rgw_oidc_provider.h"
+
namespace rgw::auth::sts {
class WebTokenEngine : public rgw::auth::Engine {
const rgw::auth::StrategyRegistry&,
const std::string&) override;
};
+