summaryrefslogtreecommitdiff
path: root/src/or/or.h
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2014-11-13 10:48:15 -0500
committerNick Mathewson <nickm@torproject.org>2015-01-06 14:31:20 -0500
commit35efce1f3f517871aaa19d60976a9abb3a67bede (patch)
tree13560f7d67e4df1e4011f6f08ff42e371ed7f0a9 /src/or/or.h
parent5c813f6ca1d6e385cfad5219108f8ac00677cf35 (diff)
downloadtor-35efce1f3f517871aaa19d60976a9abb3a67bede.tar.gz
tor-35efce1f3f517871aaa19d60976a9abb3a67bede.zip
Add an ExitRelay option to override ExitPolicy
If we're not a relay, we ignore it. If it's set to 1, we obey ExitPolicy. If it's set to 0, we force ExitPolicy to 'reject *:*' And if it's set to auto, then we warn the user if they're running an exit, and tell them how they can stop running an exit if they didn't mean to do that. Fixes ticket 10067
Diffstat (limited to 'src/or/or.h')
-rw-r--r--src/or/or.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/or/or.h b/src/or/or.h
index 5ebe7bfac3..dadf5561af 100644
--- a/src/or/or.h
+++ b/src/or/or.h
@@ -4232,6 +4232,13 @@ typedef struct {
/** Should we send the timestamps that pre-023 hidden services want? */
int Support022HiddenServices;
+ /** Is this an exit node? This is a tristate, where "1" means "yes, and use
+ * the default exit policy if none is given" and "0" means "no; exit policy
+ * is 'reject *'" and "auto" (-1) means "same as 1, but warn the user."
+ *
+ * XXXX Eventually, the default will be 0. */
+ int ExitRelay;
+
} or_options_t;
/** Persistent state for an onion router, as saved to disk. */