#24797: Add an option that makes Tor use fewer connections
 Reporter:  teor                                 |          Owner:  neel
     Type:  enhancement                          |         Status:
                                                 |  assigned
 Priority:  Medium                               |      Milestone:  Tor:
                                                 |  unspecified
Component:  Core Tor/Tor                         |        Version:
 Severity:  Normal                               |     Resolution:
 Keywords:  tor-relay, tor-dos,                  |  Actual Points:
  034-triage-20180328, 034-removed-20180328      |
Parent ID:                                       |         Points:  1
 Reviewer:                                       |        Sponsor:

Comment (by neel):

 Replying to [comment:8 arma]:

 > This one is tricky, because if we have such an option, and a Tor relay
 sets it and hits the limit, then the relay will start behaving badly.
 > We really need our relays to never hit their limit. Anything else is

 Thank You.

 I noticed this function in `src/common/compat.c`:

 int set_max_file_descriptors(rlim_t limit, int *max_out)

 Should I be working with the function above? I am thinking about an
 argument to this function with the total maximum number of connections Tor
 will take (and using that value as an alternative to the maximum number of
 file descriptors) which will in turn be used to set `max_sockets` in
 `src/common/compat.c` and the `ConnLimit_` option from the call to
 `set_max_file_descriptors()` in `config.c`. The argument will be based on
 an option I will add (if I work on this patch). If this option is `0` or
 left unset, it will default to using the number of file descriptors like
 Tor does right now.

Ticket URL: <https://trac.torproject.org/projects/tor/ticket/24797#comment:9>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
tor-bugs mailing list

Reply via email to