diff options
author | Neel Chauhan <neel@neelc.org> | 2018-09-13 21:50:06 -0400 |
---|---|---|
committer | Neel Chauhan <neel@neelc.org> | 2018-09-13 21:50:06 -0400 |
commit | 2c093c96b202a628aeb225792e0c7d95732e96ef (patch) | |
tree | 3dedfa16cdbea01e05bdf26897dc0643ea1ae2ba /src | |
parent | eb2b130ad9636a9e8c7fc6dd04f6283dcee6c9d5 (diff) | |
download | tor-2c093c96b202a628aeb225792e0c7d95732e96ef.tar.gz tor-2c093c96b202a628aeb225792e0c7d95732e96ef.zip |
Add log message for Tor being non-exit by default
Diffstat (limited to 'src')
-rw-r--r-- | src/core/or/policies.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/core/or/policies.c b/src/core/or/policies.c index 5413ad0eb5..61d3a90ff4 100644 --- a/src/core/or/policies.c +++ b/src/core/or/policies.c @@ -1155,6 +1155,17 @@ validate_addr_policies(const or_options_t *options, char **msg) REJECT("Error in ExitPolicy entry."); } + static int warned_about_nonexit = 0; + + if (!warned_about_nonexit && options->ExitPolicy == NULL && + options->ExitRelay == -1 && options->ReducedExitPolicy == 0) { + warned_about_nonexit = 1; + log_notice(LD_CONFIG, "By default, Tor does not run as an exit relay. " + "The reason is to prevent your relay from appearing as the " + "source of abusive traffic. If you want to be an exit relay, " + "set ExitRelay to 1."); + } + /* The rest of these calls *append* to addr_policy. So don't actually * use the results for anything other than checking if they parse! */ if (parse_addr_policy(options->DirPolicy, &addr_policy, -1)) |