[tor-bugs] #12538 [Tor]: Make all relays automatically be dir caches

Tor Bug Tracker & Wiki blackhole at torproject.org
Wed Nov 11 00:58:29 UTC 2015


#12538: Make all relays automatically be dir caches
-------------------------------------------------+-------------------------
 Reporter:  cypherpunks                          |          Owner:
     Type:  task                                 |         Status:
 Priority:  High                                 |  needs_review
Component:  Tor                                  |      Milestone:  Tor:
 Severity:  Normal                               |  0.2.8.x-final
 Keywords:  tor-guard, tor-relay, prop237,       |        Version:  Tor:
  026-triaged-1, sebastian-review,               |  unspecified
  027-triaged-1-out, 028-triage, 028-triaged,    |     Resolution:
  mike-can, pre028-patch                         |  Actual Points:
Parent ID:                                       |         Points:
  Sponsor:                                       |  medium/large
-------------------------------------------------+-------------------------

Comment (by sysrqb):

 Replying to [comment:77 nickm]:
 > Replying to [comment:76 teor]:
 > > Are you suggesting we remove this feature, and, if so, for relays
 using the new all-cache feature, or all directories?
 >
 > I was under the assumption that it made us stop advertising our DirPort,
 but that it left the DirPort enabled.  If it turns the DirPort off
 entirely, then it's probably okay to leave the feature as-is in this
 patch, and I am just being a forgetful old hacker.

 Your less-youngness is not affecting your memory in this case. This is
 something that I changed, although unintentionally, in the original
 branch.

 {{{
 @@ -1153,7 +1153,7 @@ directory_caches_dir_info(const or_options_t
 *options)
  int
  directory_permits_begindir_requests(const or_options_t *options)
  {
 -  return options->BridgeRelay != 0 || options->DirPort_set;
 +  return options->BridgeRelay != 0 || dir_server_mode(options);
  }
 }}}
 0061807334d54a56ba10d2ae956961291e8183d6 in feature12538_rebased_7.

 And the accounting thresholds were only used when publishing a new
 descriptor. It doesn't seem like there's a good reason for changing this
 behavior, so changing directory_permits_begindir_requests() so it doesn't
 depend on router_should_be_directory_server() seems like a good idea.

 I'm now wondering if we don't want to use dir_server_mode() other places,
 as well. In particular, currently the behavior is now different for
 caching directory info, too. Relays won't cache them if they're near their
 bandwidth usage limit. Maybe this is better than the old behavior? I'm
 thinking we should stick with what we currently do unless there's a better
 reason for doing something different.

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/12538#comment:79>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list