diff options
author | Nick Mathewson <nickm@torproject.org> | 2016-12-13 13:09:27 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2016-12-13 13:09:27 -0500 |
commit | 55d02c004c9b36258ef64ccb2def4ddcb0fb04c5 (patch) | |
tree | bea95d5ea3fef665ba39bb80826d2e8e77ab8cd7 /src/or/dirserv.c | |
parent | 56b11905e509297e3db55f62afd14afb6e6ae2eb (diff) | |
download | tor-55d02c004c9b36258ef64ccb2def4ddcb0fb04c5.tar.gz tor-55d02c004c9b36258ef64ccb2def4ddcb0fb04c5.zip |
Remove AuthDirMaxServersPerAuthAddr
Back when Roger had do do most of our testing on the moria host, we
needed a higher limit for the number of relays running on a single
IP address when that limit was shared with an authority. Nowadays,
the idea is pretty obsolete.
Also remove the router_addr_is_trusted_dir() function, which served
no other purpose.
Closes ticket 20960.
Diffstat (limited to 'src/or/dirserv.c')
-rw-r--r-- | src/or/dirserv.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/src/or/dirserv.c b/src/or/dirserv.c index e1066283de..4d349ddf16 100644 --- a/src/or/dirserv.c +++ b/src/or/dirserv.c @@ -2056,12 +2056,8 @@ get_possible_sybil_list(const smartlist_t *routers) int addr_count; /* Allow at most this number of Tor servers on a single IP address, ... */ int max_with_same_addr = options->AuthDirMaxServersPerAddr; - /* ... unless it's a directory authority, in which case allow more. */ - int max_with_same_addr_on_authority = options->AuthDirMaxServersPerAuthAddr; if (max_with_same_addr <= 0) max_with_same_addr = INT_MAX; - if (max_with_same_addr_on_authority <= 0) - max_with_same_addr_on_authority = INT_MAX; smartlist_add_all(routers_by_ip, routers); smartlist_sort(routers_by_ip, compare_routerinfo_by_ip_and_bw_); @@ -2074,9 +2070,7 @@ get_possible_sybil_list(const smartlist_t *routers) last_addr = ri->addr; addr_count = 1; } else if (++addr_count > max_with_same_addr) { - if (!router_addr_is_trusted_dir(ri->addr) || - addr_count > max_with_same_addr_on_authority) - digestmap_set(omit_as_sybil, ri->cache_info.identity_digest, ri); + digestmap_set(omit_as_sybil, ri->cache_info.identity_digest, ri); } } SMARTLIST_FOREACH_END(ri); |