diff options
author | Nick Mathewson <nickm@torproject.org> | 2012-11-25 13:18:26 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2012-12-17 14:48:08 -0500 |
commit | d3e9e03cacda3d99f3c585fd7bc00b3dd2390d61 (patch) | |
tree | b72db36bbe095fe9d59314590c8abf91940efefe /src/or/or.h | |
parent | 44a9a47706f4dbca2386b0d5cc5cd3aea5781d59 (diff) | |
download | tor-d3e9e03cacda3d99f3c585fd7bc00b3dd2390d61.tar tor-d3e9e03cacda3d99f3c585fd7bc00b3dd2390d61.tar.gz |
Add options to turn DNS cache use on or off per client port.
(This is part 1 of making DNS cache use enabled/disabled on a
per-client port basis. These options are shuffled around correctly,
but don't do anything yet.)
Diffstat (limited to 'src/or/or.h')
-rw-r--r-- | src/or/or.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/or/or.h b/src/or/or.h index 06a74f637..a2c41228d 100644 --- a/src/or/or.h +++ b/src/or/or.h @@ -1237,6 +1237,12 @@ typedef struct listener_connection_t { * addresses? */ unsigned int socks_prefer_ipv6 : 1; + /*DOCDOC*/ + unsigned int cache_ipv4_answers : 1; + unsigned int cache_ipv6_answers : 1; + unsigned int use_cached_ipv4_answers : 1; + unsigned int use_cached_ipv6_answers : 1; + } listener_connection_t; /** Minimum length of the random part of an AUTH_CHALLENGE cell. */ @@ -1545,6 +1551,12 @@ typedef struct entry_connection_t { /** Should we say we prefer IPv6 traffic? */ unsigned int prefer_ipv6_traffic : 1; + /* DOCDOC*/ + unsigned int cache_ipv4_answers : 1; + unsigned int cache_ipv6_answers : 1; + unsigned int use_cached_ipv4_answers : 1; + unsigned int use_cached_ipv6_answers : 1; + } entry_connection_t; /** Subtype of connection_t for an "directory connection" -- that is, an HTTP @@ -3084,10 +3096,18 @@ typedef struct port_cfg_t { unsigned int all_addrs : 1; unsigned int bind_ipv4_only : 1; unsigned int bind_ipv6_only : 1; + + /* Client port types only: */ unsigned int ipv4_traffic : 1; unsigned int ipv6_traffic : 1; unsigned int prefer_ipv6 : 1; + /* DOCDOC */ + unsigned int cache_ipv4_answers : 1; + unsigned int cache_ipv6_answers : 1; + unsigned int use_cached_ipv4_answers : 1; + unsigned int use_cached_ipv6_answers : 1; + /* Unix sockets only: */ /** Path for an AF_UNIX address */ char unix_addr[FLEXIBLE_ARRAY_MEMBER]; |