[tor-bugs] #25886 [Core Tor/Tor]: Have frac_nodes_with_descriptors() take and use for_direct_connect

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri Jun 15 23:36:29 UTC 2018


#25886: Have frac_nodes_with_descriptors() take and use for_direct_connect
-------------------------------------------------+-------------------------
 Reporter:  nickm                                |          Owner:  neel
     Type:  defect                               |         Status:
                                                 |  needs_revision
 Priority:  Medium                               |      Milestone:  Tor:
                                                 |  0.3.5.x-final
Component:  Core Tor/Tor                         |        Version:
 Severity:  Normal                               |     Resolution:
 Keywords:  tor-bridge-client, tor-guard,        |  Actual Points:
  bootstrap                                      |
Parent ID:                                       |         Points:
 Reviewer:  dgoulet                              |        Sponsor:
-------------------------------------------------+-------------------------

Comment (by teor):

 Replying to [comment:13 neel]:
 > Thank you for your response.
 >
 > I don't fully know what a "full descriptor" is.

 A router descriptor, rather than a microdescriptor:
 https://gitweb.torproject.org/torspec.git/tree/dir-spec.txt#n151

 > Does this mean that for bridges:
 >  * We have `node->ri` only? (based on `node_has_preferred_descriptor()`)

 ri (router info) is used to store router descriptors.

 >  * We have `node->ri`, `node->rs`, and `node->md`? (I am guessing this
 one)

 Bridges don't have rs (router status) or md (microdescriptor), because
 bridges are not in the consensus.

 > Also, I did not see any function in `bridges.h` which directly checks
 for full descriptors (or didn't see them if they were unobvious).
 >
 > The closest thing I saw were functions which get a list of bridges
 (`bridge_list_get()`) so then I get a `SMARTLIST`, and in each iteration
 get a `node_t` from the `bridge_info_t` and check for a full descriptor.
 Should I do this? If not, which function should I use?

 `num_bridges_usable(0) > 0`, which is actually in entrynodes.h :
 https://github.com/torproject/tor/blob/5edc72a45b7479f5fe791054aa19f6b3b478c725/src/or/entrynodes.c#L3149

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


More information about the tor-bugs mailing list