Proxy

A proxy endpoint, either a network service or a local unix domain socket.

Synopsis

Declared in <netbase.h>

class Proxy;

Member Functions

NameDescription
Proxy [constructor]Constructors
Connect Open a connection to this proxy.
GetFamily Get the socket address family of this proxy.
IsValid Check whether this proxy is valid.
ToString Get a human-readable representation of this proxy.

Data Members

NameDescription
m_is_unix_socket Whether this proxy is a local unix domain socket.
m_tor_stream_isolation Whether Tor stream isolation is enabled for this proxy.
m_unix_socket_path Filesystem path of the unix domain socket (unused for service proxies).
proxy The proxy network service address (unused for unix socket proxies).

Non-Member Functions

NameDescription
ConnectThroughProxyConnect to a specified destination service through a SOCKS5 proxy by first connecting to the SOCKS5 proxy.
GetNameProxyGet the configured name proxy, if any.
GetProxyGet the proxy configured for a given network, if any.
SetNameProxySet the name proxy to use for all connections to nodes specified by a hostname. After setting this proxy, connecting to a node specified by a hostname won't result in a local lookup of said hostname, rather, connect to the node by asking the name proxy for a proxy connection to the hostname, effectively delegating the hostname lookup to the specified proxy.