mirror of
https://github.com/monero-project/monero.git
synced 2025-05-06 07:54:59 -04:00
Adding HTTP Digest Auth (but not yet enabled)
This commit is contained in:
parent
1a286061ff
commit
bdc3d7496f
12 changed files with 1165 additions and 7 deletions
|
@ -52,7 +52,8 @@ namespace epee
|
|||
: m_net_server(external_io_service)
|
||||
{}
|
||||
|
||||
bool init(const std::string& bind_port = "0", const std::string& bind_ip = "0.0.0.0", const std::string &user_agent = "")
|
||||
bool init(const std::string& bind_port = "0", const std::string& bind_ip = "0.0.0.0",
|
||||
std::string user_agent = "", boost::optional<net_utils::http::http_auth::login> user = boost::none)
|
||||
{
|
||||
|
||||
//set self as callback handler
|
||||
|
@ -62,7 +63,8 @@ namespace epee
|
|||
m_net_server.get_config_object().m_folder = "";
|
||||
|
||||
// workaround till we get auth/encryption
|
||||
m_net_server.get_config_object().m_required_user_agent = user_agent;
|
||||
m_net_server.get_config_object().m_required_user_agent = std::move(user_agent);
|
||||
m_net_server.get_config_object().m_user = std::move(user);
|
||||
|
||||
LOG_PRINT_L0("Binding on " << bind_ip << ":" << bind_port);
|
||||
bool res = m_net_server.init_server(bind_port, bind_ip);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue