Clean up BMCWEB_ENABLE_SSL
This macro came originally from CROW_ENABLE_SSL, and was used as a macro
to optionally compile without openssl being required.
OpenSSL has been pulled into many other dependencies, and has been
functionally required to be included for a long time, so there's no
reason to hold onto this macro.
Remove most uses of the macro, and for the couple functional places the
macro is used, transition to a constexpr if to enable the TLS paths.
This allows a large simplification of code in some places.
Tested: Redfish service validator passes.
Change-Id: Iebd46a68e5e417b6031479e24be3c21bef782f4c
Signed-off-by: Ed Tanous <ed@tanous.net>
diff --git a/http/routing/websocketrule.hpp b/http/routing/websocketrule.hpp
index bf6daad..b52d9ec 100644
--- a/http/routing/websocketrule.hpp
+++ b/http/routing/websocketrule.hpp
@@ -27,7 +27,6 @@
asyncResp->res.result(boost::beast::http::status::not_found);
}
-#ifndef BMCWEB_ENABLE_SSL
void handleUpgrade(const Request& req,
const std::shared_ptr<bmcweb::AsyncResp>& /*asyncResp*/,
boost::asio::ip::tcp::socket&& adaptor) override
@@ -41,7 +40,7 @@
messageHandler, messageExHandler, closeHandler, errorHandler);
myConnection->start(req);
}
-#else
+
void handleUpgrade(const Request& req,
const std::shared_ptr<bmcweb::AsyncResp>& /*asyncResp*/,
boost::beast::ssl_stream<boost::asio::ip::tcp::socket>&&
@@ -56,7 +55,6 @@
messageHandler, messageExHandler, closeHandler, errorHandler);
myConnection->start(req);
}
-#endif
template <typename Func>
self_t& onopen(Func f)