Add server auth to monerod, and client auth to wallet-cli and wallet-rpc

This commit is contained in:
Lee Clagett
2017-02-05 17:48:03 -05:00
parent e56bf442c3
commit ce7fcbb4ae
38 changed files with 495 additions and 189 deletions
+5 -1
View File
@@ -28,10 +28,13 @@
#pragma once
#include <boost/optional/optional.hpp>
#include "common/http_connection.h"
#include "common/scoped_message_writer.h"
#include "rpc/core_rpc_server_commands_defs.h"
#include "storages/http_abstract_invoke.h"
#include "net/http_auth.h"
#include "net/http_client.h"
#include "string_tools.h"
@@ -45,11 +48,12 @@ namespace tools
t_rpc_client(
uint32_t ip
, uint16_t port
, boost::optional<epee::net_utils::http::login> user
)
: m_http_client{}
{
m_http_client.set_server(
epee::string_tools::get_ip_string_from_int32(ip), std::to_string(port)
epee::string_tools::get_ip_string_from_int32(ip), std::to_string(port), std::move(user)
);
}