1#include <xrpld/app/main/Application.h>
2#include <xrpld/app/misc/NetworkOPs.h>
3#include <xrpld/core/ConfigSections.h>
4#include <xrpld/overlay/Overlay.h>
5#include <xrpld/rpc/RPCHandler.h>
6#include <xrpld/rpc/Role.h>
7#include <xrpld/rpc/ServerHandler.h>
8#include <xrpld/rpc/detail/Tuning.h>
9#include <xrpld/rpc/detail/WSInfoSub.h>
10#include <xrpld/rpc/json_body.h>
12#include <xrpl/basics/Log.h>
13#include <xrpl/basics/base64.h>
14#include <xrpl/basics/contract.h>
15#include <xrpl/basics/make_SSLContext.h>
16#include <xrpl/beast/net/IPAddressConversion.h>
17#include <xrpl/beast/rfc2616.h>
18#include <xrpl/core/JobQueue.h>
19#include <xrpl/json/json_reader.h>
20#include <xrpl/json/to_string.h>
21#include <xrpl/protocol/ApiVersion.h>
22#include <xrpl/protocol/ErrorCodes.h>
23#include <xrpl/protocol/RPCErr.h>
24#include <xrpl/resource/Fees.h>
25#include <xrpl/resource/ResourceManager.h>
26#include <xrpl/server/Server.h>
27#include <xrpl/server/SimpleWriter.h>
28#include <xrpl/server/detail/JSONRPCUtil.h>
30#include <boost/algorithm/string.hpp>
31#include <boost/beast/http/fields.hpp>
32#include <boost/beast/http/string_body.hpp>
49 return request.version() >= 11 && request.target() ==
"/" &&
50 request.body().size() == 0 &&
51 request.method() == boost::beast::http::verb::get;
57 boost::beast::http::status status)
59 using namespace boost::beast::http;
61 response<string_body> msg;
62 msg.version(request.version());
65 msg.insert(
"Content-Type",
"text/html");
66 msg.insert(
"Connection",
"close");
67 msg.body() =
"Invalid protocol.";
68 msg.prepare_payload();
80 auto const it = h.
find(
"authorization");
81 if ((it == h.
end()) || (it->second.substr(0, 6) !=
"Basic "))
84 boost::trim(strUserPass64);
86 std::string::size_type nColon = strUserPass.
find(
":");
87 if (nColon == std::string::npos)
91 return strUser == port.
user && strPassword == port.
password;
97 boost::asio::io_context& io_context,
103 , m_resourceManager(resourceManager)
104 , m_journal(app_.journal(
"Server"))
105 , m_networkOPs(networkOPs)
106 , m_server(
make_Server(*this, io_context, app_.journal(
"Server")))
107 , m_jobQueue(jobQueue)
109 auto const& group(cm.
group(
"rpc"));
131 auto const endpointPort = it->second.port();
133 port.port = endpointPort;
136 (port.protocol.count(
"http") > 0 ||
137 port.protocol.count(
"https") > 0))
140 if (!
setup_.
overlay.port() && (port.protocol.count(
"peer") > 0))
163 boost::asio::ip::tcp::endpoint endpoint)
165 auto const& port = session.
port();
167 auto const c = [
this, &port]() {
172 if (port.limit && c >= port.limit)
175 << port.name <<
" is full; dropping " << endpoint;
187 boost::asio::ip::tcp::endpoint
const& remote_address)
189 using namespace boost::beast;
192 p.
count(
"ws") > 0 || p.count(
"ws2") > 0 || p.count(
"wss") > 0 ||
193 p.count(
"wss2") > 0};
195 if (websocket::is_upgrade(request))
208 <<
"Exception upgrading websocket: " << e.
what() <<
"\n";
210 request, http::status::internal_server_error);
214 auto const beast_remote_address =
218 beast_remote_address,
223 beast_remote_address,
226 is->forwarded_for());
227 ws->appDefined = std::move(is);
231 handoff.
moved =
true;
235 if (bundle && p.count(
"peer") > 0)
237 std::move(bundle), std::move(request), remote_address);
249 return [&](boost::beast::string_view
const& b) {
250 session.
write(b.data(), b.size());
258 for (
auto const& e : h)
264 return std::tolower(static_cast<unsigned char>(kc));
271template <
class ConstBufferSequence>
275 using boost::asio::buffer_size;
281 s.
append(
static_cast<char const*
>(b.data()), buffer_size(b));
312 if (postResult ==
nullptr)
317 "Service Unavailable",
320 detachedSession->close(
true);
331 auto const size = boost::asio::buffer_size(buffers);
336 jvResult[jss::type] = jss::error;
337 jvResult[jss::error] =
"jsonInvalid";
339 boost::beast::multi_buffer sb;
340 Json::stream(jvResult, [&sb](
auto const p,
auto const n) {
341 sb.commit(boost::asio::buffer_copy(
342 sb.prepare(n), boost::asio::buffer(p, n)));
344 JLOG(
m_journal.
trace()) <<
"Websocket sending '" << jvResult <<
"'";
356 [
this, session, jv = std::move(jv)](
360 auto const n = s.length();
361 boost::beast::multi_buffer sb(n);
362 sb.commit(boost::asio::buffer_copy(
363 sb.prepare(n), boost::asio::buffer(s.c_str(), n)));
368 if (postResult ==
nullptr)
371 session->close({boost::beast::websocket::going_away,
"Shutting Down"});
399 using namespace std::chrono_literals;
400 auto const level = (duration >= 10s) ? journal.
error()
401 : (duration >= 1s) ? journal.
warn()
404 JLOG(level) <<
"RPC request processing duration = "
405 << std::chrono::duration_cast<std::chrono::microseconds>(
408 <<
" microseconds. request = " << request;
418 if (is->getConsumer().disconnect(
m_journal))
421 {boost::beast::websocket::policy_error,
"threshold exceeded"});
441 jr[jss::type] = jss::response;
442 jr[jss::status] = jss::error;
444 ? jss::invalid_API_version
445 : jss::missingCommand;
446 jr[jss::request] = jv;
448 jr[jss::id] = jv[jss::id];
450 jr[jss::jsonrpc] = jv[jss::jsonrpc];
452 jr[jss::ripplerpc] = jv[jss::ripplerpc];
454 jr[jss::api_version] = jv[jss::api_version];
490 {is->user(), is->forwarded_for()}};
503 <<
"Exception while processing WS: " << ex.
what() <<
"\n"
508 is->getConsumer().charge(loadType);
509 if (is->getConsumer().warn())
510 jr[jss::warning] = jss::load;
517 if (jr[jss::result].isMember(jss::error))
519 jr = jr[jss::result];
520 jr[jss::status] = jss::error;
526 if (rq.isMember(jss::passphrase.c_str()))
527 rq[jss::passphrase.c_str()] =
"<masked>";
528 if (rq.isMember(jss::secret.c_str()))
529 rq[jss::secret.c_str()] =
"<masked>";
530 if (rq.isMember(jss::seed.c_str()))
531 rq[jss::seed.c_str()] =
"<masked>";
532 if (rq.isMember(jss::seed_hex.c_str()))
533 rq[jss::seed_hex.c_str()] =
"<masked>";
536 jr[jss::request] = rq;
540 if (jr[jss::result].isMember(
"forwarded") &&
541 jr[jss::result][
"forwarded"])
542 jr = jr[jss::result];
543 jr[jss::status] = jss::success;
547 jr[jss::id] = jv[jss::id];
549 jr[jss::jsonrpc] = jv[jss::jsonrpc];
551 jr[jss::ripplerpc] = jv[jss::ripplerpc];
553 jr[jss::api_version] = jv[jss::api_version];
555 jr[jss::type] = jss::response;
568 session->remoteAddress().at_port(0),
573 auto const iter = session->request().find(
"X-User");
574 if (iter != session->request().end())
575 return iter->value();
576 return boost::beast::string_view{};
582 session->close(
true);
590 sub[
"message"] = std::move(message);
602ServerHandler::processRequest(
611 auto rpcJ = app_.journal(
"RPC");
616 if ((request.
size() > RPC::Tuning::maxRequestSize) ||
617 !reader.
parse(request, jsonOrig) || !jsonOrig ||
622 "Unable to parse request: " +
632 if (jsonOrig.
isMember(jss::method) && jsonOrig[jss::method] ==
"batch")
635 if (!jsonOrig.
isMember(jss::params) || !jsonOrig[jss::params].
isArray())
637 HTTPReply(400,
"Malformed batch request", output, rpcJ);
640 size = jsonOrig[jss::params].
size();
645 for (
unsigned i = 0; i < size; ++i)
648 batch ? jsonOrig[jss::params][i] : jsonOrig;
653 r[jss::request] = jsonRPC;
660 unsigned apiVersion = RPC::apiVersionIfUnspecified;
662 jsonRPC[jss::params].
size() > 0 &&
663 jsonRPC[jss::params][0u].
isObject())
665 apiVersion = RPC::getAPIVersionNumber(
667 app_.config().BETA_RPC_API);
670 if (apiVersion == RPC::apiVersionIfUnspecified &&
batch)
674 RPC::getAPIVersionNumber(jsonRPC, app_.config().BETA_RPC_API);
677 if (apiVersion == RPC::apiInvalidVersion)
681 HTTPReply(400, jss::invalid_API_version.c_str(), output, rpcJ);
685 r[jss::request] = jsonRPC;
693 auto role = Role::FORBID;
694 auto required = Role::FORBID;
696 required = RPC::roleRequired(
698 app_.config().BETA_RPC_API,
702 jsonRPC[jss::params].
size() > 0 &&
721 usage = m_resourceManager.newUnlimitedEndpoint(remoteIPAddress);
725 usage = m_resourceManager.newInboundEndpoint(
731 HTTPReply(503,
"Server is overloaded", output, rpcJ);
742 if (role == Role::FORBID)
744 usage.
charge(Resource::feeMalformedRPC);
747 HTTPReply(403,
"Forbidden", output, rpcJ);
756 if (!jsonRPC.
isMember(jss::method) || jsonRPC[jss::method].
isNull())
758 usage.
charge(Resource::feeMalformedRPC);
761 HTTPReply(400,
"Null method", output, rpcJ);
773 usage.
charge(Resource::feeMalformedRPC);
776 HTTPReply(400,
"method is not string", output, rpcJ);
787 if (strMethod.
empty())
789 usage.
charge(Resource::feeMalformedRPC);
792 HTTPReply(400,
"method is empty", output, rpcJ);
811 params = jsonRPC[jss::params];
817 usage.
charge(Resource::feeMalformedRPC);
818 HTTPReply(400,
"params unparsable", output, rpcJ);
823 params = std::move(params[0u]);
826 usage.
charge(Resource::feeMalformedRPC);
827 HTTPReply(400,
"params unparsable", output, rpcJ);
838 if (params.
isMember(jss::ripplerpc))
840 if (!params[jss::ripplerpc].isString())
842 usage.
charge(Resource::feeMalformedRPC);
845 HTTPReply(400,
"ripplerpc is not a string", output, rpcJ);
855 ripplerpc = params[jss::ripplerpc].
asString();
862 if (role != Role::IDENTIFIED && role != Role::PROXY)
868 JLOG(m_journal.debug()) <<
"Query: " << strMethod << params;
871 params[jss::command] = strMethod;
872 JLOG(m_journal.trace())
873 <<
"doRpcCommand:" << strMethod <<
":" << params;
882 app_.getLedgerMaster(),
896 RPC::doCommand(context, result);
902 JLOG(m_journal.error()) <<
"Internal error : " << ex.
what()
903 <<
" when processing request: "
914 result[jss::warning] = jss::load;
917 if (ripplerpc >=
"2.0")
921 result[jss::status] = jss::error;
922 result[
"code"] = result[jss::error_code];
923 result[
"message"] = result[jss::error_message];
925 JLOG(m_journal.debug()) <<
"rpcError: " << result[jss::error]
926 <<
": " << result[jss::error_message];
927 r[jss::error] = std::move(result);
931 result[jss::status] = jss::success;
932 r[jss::result] = std::move(result);
945 if (rq.isMember(jss::passphrase.c_str()))
946 rq[jss::passphrase.c_str()] =
"<masked>";
947 if (rq.isMember(jss::secret.c_str()))
948 rq[jss::secret.c_str()] =
"<masked>";
949 if (rq.isMember(jss::seed.c_str()))
950 rq[jss::seed.c_str()] =
"<masked>";
951 if (rq.isMember(jss::seed_hex.c_str()))
952 rq[jss::seed_hex.c_str()] =
"<masked>";
955 result[jss::status] = jss::error;
956 result[jss::request] = rq;
958 JLOG(m_journal.debug()) <<
"rpcError: " << result[jss::error]
959 <<
": " << result[jss::error_message];
963 result[jss::status] = jss::success;
965 r[jss::result] = std::move(result);
969 r[jss::jsonrpc] = params[jss::jsonrpc];
970 if (params.
isMember(jss::ripplerpc))
971 r[jss::ripplerpc] = params[jss::ripplerpc];
973 r[jss::id] = params[jss::id];
975 reply.
append(std::move(r));
977 reply = std::move(r);
980 reply[jss::result].
isMember(jss::result))
982 reply = reply[jss::result];
985 reply[jss::result][jss::status] = reply[jss::status];
992 int const httpStatus = [&reply]() {
995 if (reply.
isMember(jss::ripplerpc) &&
997 reply[jss::ripplerpc].
asString() >=
"3.0")
1001 reply[jss::error].
isMember(jss::error_code) &&
1002 reply[jss::error][jss::error_code].
isInt())
1004 int const errCode = reply[jss::error][jss::error_code].
asInt();
1005 return RPC::error_code_http_status(
1013 auto response = to_string(reply);
1015 rpc_time_.notify(std::chrono::duration_cast<std::chrono::milliseconds>(
1022 if (
auto stream = m_journal.debug())
1024 static int const maxSize = 10000;
1025 if (response.size() <= maxSize)
1026 stream <<
"Reply: " << response;
1028 stream <<
"Reply: " << response.substr(0, maxSize);
1031 HTTPReply(httpStatus, response, output, rpcJ);
1043 using namespace boost::beast::http;
1045 response<string_body> msg;
1047 if (app_.serverOkay(reason))
1049 msg.result(boost::beast::http::status::ok);
1050 msg.body() =
"<!DOCTYPE html><html><head><title>" + systemName() +
1051 " Test page for rippled</title></head><body><h1>" + systemName() +
1052 " Test</h1><p>This page shows rippled http(s) "
1053 "connectivity is working.</p></body></html>";
1057 msg.result(boost::beast::http::status::internal_server_error);
1058 msg.body() =
"<HTML><BODY>Server cannot accept clients: " + reason +
1061 msg.version(request.version());
1062 msg.
insert(
"Server", BuildInfo::getFullVersionString());
1063 msg.insert(
"Content-Type",
"text/html");
1064 msg.insert(
"Connection",
"close");
1065 msg.prepare_payload();
1073ServerHandler::Setup::makeContexts()
1075 for (
auto& p : ports)
1079 if (p.ssl_key.empty() && p.ssl_cert.empty() && p.ssl_chain.empty())
1083 p.ssl_key, p.ssl_cert, p.ssl_chain, p.ssl_ciphers);
1088 boost::asio::ssl::context::sslv23);
1101 log <<
"Missing 'ip' in [" << p.
name <<
"]";
1102 Throw<std::exception>();
1108 log <<
"Missing 'port' in [" << p.
name <<
"]";
1109 Throw<std::exception>();
1115 log <<
"Missing 'protocol' in [" << p.
name <<
"]";
1116 Throw<std::exception>();
1144 if (!config.
exists(
"server"))
1146 log <<
"Required section [server] is missing";
1147 Throw<std::exception>();
1155 for (
auto const& name : names)
1157 if (!config.
exists(name))
1159 log <<
"Missing section: [" << name <<
"]";
1160 Throw<std::exception>();
1165 if (name == SECTION_PORT_GRPC)
1175 auto it = result.
begin();
1177 while (it != result.
end())
1179 auto& p = it->protocol;
1183 if (p.erase(
"peer") && p.empty())
1184 it = result.
erase(it);
1193 return p.protocol.count(
"peer") != 0;
1198 log <<
"Error: More than one peer protocol configured in [server]";
1199 Throw<std::exception>();
1203 log <<
"Warning: No peer protocol configured";
1213 decltype(setup.
ports)::const_iterator iter;
1214 for (iter = setup.
ports.cbegin(); iter != setup.
ports.cend(); ++iter)
1215 if (iter->protocol.count(
"http") > 0 ||
1216 iter->protocol.count(
"https") > 0)
1218 if (iter == setup.
ports.cend())
1220 setup.
client.
secure = iter->protocol.count(
"https") > 0;
1224 (iter->ip.is_v6() ?
"::1" :
"127.0.0.1")
1225 : iter->ip.to_string();
1239 return port.protocol.count(
"peer") != 0;
1241 if (iter == setup.
ports.cend())
1246 setup.
overlay = {iter->ip, iter->port};
1264 boost::asio::io_context& io_context,
Decorator for streaming out compact json.
Unserialize a JSON document into a Value.
std::string getFormattedErrorMessages() const
Returns a user friendly string that list errors in the parsed document.
bool parse(std::string const &document, Value &root)
Read a Value from a JSON document.
Value & append(Value const &value)
Append value to array at the end.
UInt size() const
Number of values in array or object.
bool isObjectOrNull() const
Value removeMember(char const *key)
Remove and return the named member.
std::string asString() const
Returns the unquoted string value.
bool isNull() const
isNull() tests to see if this field is null.
bool isMember(char const *key) const
Return true if the object has a member named key.
A version-independent IP address and port combination.
A generic endpoint for log messages.
Stream trace() const
Severity stream access functions.
virtual Config & config()=0
virtual LedgerMaster & getLedgerMaster()=0
virtual beast::Journal journal(std::string const &name)=0
virtual Overlay & overlay()=0
virtual NetworkOPs & getOPs()=0
bool exists(std::string const &name) const
Returns true if a section with the given name exists.
Section & section(std::string const &name)
Returns the section with the given name.
Provides the beast::insight::Collector service.
virtual beast::insight::Group::ptr const & group(std::string const &name)=0
A pool of threads to perform work.
std::shared_ptr< Coro > postCoro(JobType t, std::string const &name, F &&f)
Creates a coroutine and adds a job to the queue which will run it.
Provides server functionality for clients.
virtual Handoff onHandoff(std::unique_ptr< stream_type > &&bundle, http_request_type &&request, boost::asio::ip::tcp::endpoint remote_address)=0
Conditionally accept an incoming HTTP request.
An endpoint that consumes resources.
bool warn()
Returns true if the consumer should be warned.
bool disconnect(beast::Journal const &j)
Returns true if the consumer should be disconnected.
Disposition charge(Charge const &fee, std::string const &context={})
Apply a load charge to the consumer.
Tracks load and resource consumption.
std::vector< std::string > const & values() const
Returns all the values in the section.
Resource::Manager & m_resourceManager
std::condition_variable condition_
ServerHandler(ServerHandlerCreator const &, Application &app, boost::asio::io_context &io_context, JobQueue &jobQueue, NetworkOPs &networkOPs, Resource::Manager &resourceManager, CollectorManager &cm)
Handoff onHandoff(Session &session, std::unique_ptr< stream_type > &&bundle, http_request_type &&request, boost::asio::ip::tcp::endpoint const &remote_address)
void onClose(Session &session, boost::system::error_code const &)
Setup const & setup() const
bool onAccept(Session &session, boost::asio::ip::tcp::endpoint endpoint)
beast::insight::Event rpc_size_
Handoff statusResponse(http_request_type const &request) const
void processRequest(Port const &port, std::string const &request, beast::IP::Endpoint const &remoteIPAddress, Output &&, std::shared_ptr< JobQueue::Coro > coro, std::string_view forwardedFor, std::string_view user)
std::map< std::reference_wrapper< Port const >, int > count_
void onRequest(Session &session)
beast::insight::Event rpc_time_
void onWSMessage(std::shared_ptr< WSSession > session, std::vector< boost::asio::const_buffer > const &buffers)
NetworkOPs & m_networkOPs
std::unique_ptr< Server > m_server
beast::insight::Counter rpc_requests_
Json::Value processSession(std::shared_ptr< WSSession > const &session, std::shared_ptr< JobQueue::Coro > const &coro, Json::Value const &jv)
Persistent state information for a connection session.
virtual Port const & port()=0
Returns the Port settings for this connection.
virtual void close(bool graceful)=0
Close the session.
virtual std::shared_ptr< Session > detach()=0
Detach the session.
virtual http_request_type & request()=0
Returns the current HTTP request.
virtual std::shared_ptr< WSSession > websocketUpgrade()=0
Convert the connection to WebSocket.
void write(std::string const &s)
Send a copy of data asynchronously.
void stream(Json::Value const &jv, Write const &write)
Stream compact JSON to the specified function.
@ arrayValue
array value (ordered list)
@ objectValue
object value (collection of name/value pairs).
Endpoint from_asio(boost::asio::ip::address const &address)
Convert to Endpoint.
bool is_unspecified(Address const &addr)
Returns true if the address is unspecified.
bool is_keep_alive(boost::beast::http::message< isRequest, Body, Fields > const &m)
std::string const & getFullVersionString()
Full server version string.
static int constexpr maxRequestSize
static constexpr auto apiInvalidVersion
Role roleRequired(unsigned int version, bool betaEnabled, std::string const &method)
Status doCommand(RPC::JsonContext &context, Json::Value &result)
Execute an RPC command and store the results in a Json::Value.
unsigned int getAPIVersionNumber(Json::Value const &jv, bool betaEnabled)
Retrieve the api version number from the json value.
Json::Value make_error(error_code_i code)
Returns a new json object that reflects the error code.
Charge const feeReferenceRPC
Charge const feeMalformedRPC
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
static std::map< std::string, std::string > build_map(boost::beast::http::fields const &h)
void parse_Port(ParsedPort &port, Section const §ion, std::ostream &log)
void HTTPReply(int nStatus, std::string const &strMsg, Json::Output const &, beast::Journal j)
static std::string buffers_to_string(ConstBufferSequence const &bs)
std::string to_string(base_uint< Bits, Tag > const &a)
static void setup_Client(ServerHandler::Setup &setup)
boost::beast::http::request< boost::beast::http::dynamic_body > http_request_type
std::string base64_decode(std::string_view data)
static std::vector< Port > parse_Ports(Config const &config, std::ostream &log)
Json::Int constexpr wrong_version
std::shared_ptr< boost::asio::ssl::context > make_SSLContext(std::string const &cipherList)
Create a self-signed SSL context that allows anonymous Diffie Hellman.
static bool authorized(Port const &port, std::map< std::string, std::string > const &h)
Role requestRole(Role const &required, Port const &port, Json::Value const ¶ms, beast::IP::Endpoint const &remoteIp, std::string_view user)
Return the allowed privilege role.
Resource::Consumer requestInboundEndpoint(Resource::Manager &manager, beast::IP::Endpoint const &remoteAddress, Role const &role, std::string_view user, std::string_view forwardedFor)
static Json::Value make_json_error(Json::Int code, Json::Value &&message)
std::string_view forwardedFor(http_request_type const &request)
ServerHandler::Setup setup_ServerHandler(Config const &config, std::ostream &&log)
static Port to_Port(ParsedPort const &parsed, std::ostream &log)
std::unique_ptr< ServerHandler > make_ServerHandler(Application &app, boost::asio::io_context &io_context, JobQueue &jobQueue, NetworkOPs &networkOPs, Resource::Manager &resourceManager, CollectorManager &cm)
Json::Int constexpr forbidden
Json::Value rpcError(error_code_i iError)
Json::Int constexpr method_not_found
std::unique_ptr< Server > make_Server(Handler &handler, boost::asio::io_context &io_context, beast::Journal journal)
Create the HTTP server using the specified handler.
Json::Int constexpr server_overloaded
void logDuration(Json::Value const &request, T const &duration, beast::Journal &journal)
Overlay::Setup setup_Overlay(BasicConfig const &config)
bool isUnlimited(Role const &role)
ADMIN and IDENTIFIED roles shall have unlimited resources.
std::shared_ptr< boost::asio::ssl::context > make_SSLContextAuthed(std::string const &keyFile, std::string const &certFile, std::string const &chainFile, std::string const &cipherList)
Create an authenticated SSL context using the specified files.
static Json::Output makeOutput(Session &session)
static bool isStatusRequest(http_request_type const &request)
static Handoff statusRequestResponse(http_request_type const &request, boost::beast::http::status status)
T remove_suffix(T... args)
static IP::Endpoint from_asio(boost::asio::ip::address const &address)
Used to indicate the result of a server connection handoff.
std::shared_ptr< Writer > response
std::set< std::string, boost::beast::iless > protocol
boost::beast::websocket::permessage_deflate pmd_options
std::optional< boost::asio::ip::address > ip
std::vector< boost::asio::ip::network_v6 > secure_gateway_nets_v6
std::string admin_password
std::vector< boost::asio::ip::network_v4 > secure_gateway_nets_v4
std::uint16_t ws_queue_limit
std::vector< boost::asio::ip::network_v4 > admin_nets_v4
std::optional< std::uint16_t > port
std::vector< boost::asio::ip::network_v6 > admin_nets_v6
Configuration information for a Server listening port.
std::vector< boost::asio::ip::network_v4 > admin_nets_v4
std::string admin_password
std::vector< boost::asio::ip::network_v6 > secure_gateway_nets_v6
std::set< std::string, boost::beast::iless > protocol
boost::beast::websocket::permessage_deflate pmd_options
std::uint16_t ws_queue_limit
boost::asio::ip::address ip
std::vector< boost::asio::ip::network_v4 > secure_gateway_nets_v4
std::vector< boost::asio::ip::network_v6 > admin_nets_v6
std::string admin_password
boost::asio::ip::tcp::endpoint overlay
std::vector< Port > ports