aboutsummaryrefslogtreecommitdiff
path: root/contrib/epee/include/net/http_server_impl_base.h
diff options
context:
space:
mode:
authorLee Clagett <code@leeclagett.com>2019-03-15 00:03:32 -0400
committerLee Clagett <code@leeclagett.com>2019-04-07 00:44:37 -0400
commit21eb1b0725717ad013d3e2b00fbfc3b84ad04699 (patch)
tree45c437eda5dc39120263bd2a32b70aef23aa90cd /contrib/epee/include/net/http_server_impl_base.h
parentChange default SSL to "enabled" if user specifies fingerprint/certificate (diff)
downloadmonero-21eb1b0725717ad013d3e2b00fbfc3b84ad04699.tar.xz
Pass SSL arguments via one class and use shared_ptr instead of reference
Diffstat (limited to 'contrib/epee/include/net/http_server_impl_base.h')
-rw-r--r--contrib/epee/include/net/http_server_impl_base.h8
1 files changed, 2 insertions, 6 deletions
diff --git a/contrib/epee/include/net/http_server_impl_base.h b/contrib/epee/include/net/http_server_impl_base.h
index 8a6b32943..fc2dcbf67 100644
--- a/contrib/epee/include/net/http_server_impl_base.h
+++ b/contrib/epee/include/net/http_server_impl_base.h
@@ -59,11 +59,7 @@ namespace epee
bool init(std::function<void(size_t, uint8_t*)> rng, const std::string& bind_port = "0", const std::string& bind_ip = "0.0.0.0",
std::vector<std::string> access_control_origins = std::vector<std::string>(),
boost::optional<net_utils::http::login> user = boost::none,
- epee::net_utils::ssl_support_t ssl_support = epee::net_utils::ssl_support_t::e_ssl_support_autodetect,
- const std::pair<std::string, std::string> &private_key_and_certificate_path = {},
- const std::string &ca_path = {},
- std::vector<std::vector<uint8_t>> allowed_fingerprints = {},
- bool allow_any_cert = false)
+ net_utils::ssl_options_t ssl_options = net_utils::ssl_support_t::e_ssl_support_autodetect)
{
//set self as callback handler
@@ -80,7 +76,7 @@ namespace epee
m_net_server.get_config_object().m_user = std::move(user);
MGINFO("Binding on " << bind_ip << ":" << bind_port);
- bool res = m_net_server.init_server(bind_port, bind_ip, ssl_support, private_key_and_certificate_path, ca_path, std::move(allowed_fingerprints), allow_any_cert);
+ bool res = m_net_server.init_server(bind_port, bind_ip, std::move(ssl_options));
if(!res)
{
LOG_ERROR("Failed to bind server");