diff options
author | teor <teor@torproject.org> | 2019-10-30 16:55:21 +1000 |
---|---|---|
committer | teor <teor@torproject.org> | 2019-10-31 12:34:20 +1000 |
commit | 8036954bf5fd6bd6752b3e4b4e6c52e68dd4ddcb (patch) | |
tree | 04e1a5e1512ca8241a4bc7e507cdeaccbf746822 /src/app/config/config.c | |
parent | 23faa03ffc28e8d1132370e861756e84d659be5e (diff) | |
download | tor-8036954bf5fd6bd6752b3e4b4e6c52e68dd4ddcb.tar.gz tor-8036954bf5fd6bd6752b3e4b4e6c52e68dd4ddcb.zip |
config: Move warn_nonlocal_ext_orports() to relay
Part of 32213.
Diffstat (limited to 'src/app/config/config.c')
-rw-r--r-- | src/app/config/config.c | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/src/app/config/config.c b/src/app/config/config.c index 901ed92e57..e568d0a580 100644 --- a/src/app/config/config.c +++ b/src/app/config/config.c @@ -5632,27 +5632,6 @@ warn_nonlocal_client_ports(const smartlist_t *ports, } SMARTLIST_FOREACH_END(port); } -/** Warn for every Extended ORPort port in <b>ports</b> that is on a - * publicly routable address. */ -static void -warn_nonlocal_ext_orports(const smartlist_t *ports, const char *portname) -{ - SMARTLIST_FOREACH_BEGIN(ports, const port_cfg_t *, port) { - if (port->type != CONN_TYPE_EXT_OR_LISTENER) - continue; - if (port->is_unix_addr) - continue; - /* XXX maybe warn even if address is RFC1918? */ - if (!tor_addr_is_internal(&port->addr, 1)) { - log_warn(LD_CONFIG, "You specified a public address '%s' for %sPort. " - "This is not advised; this address is supposed to only be " - "exposed on localhost so that your pluggable transport " - "proxies can connect to it.", - fmt_addrport(&port->addr, port->port), portname); - } - } SMARTLIST_FOREACH_END(port); -} - /** Given a list of port_cfg_t in <b>ports</b>, warn if any controller port * there is listening on any non-loopback address. If <b>forbid_nonlocal</b> * is true, then emit a stronger warning and remove the port from the list. |