[tor-bugs] #23989 [Core Tor/Tor]: entry_guards_update_all() will pretend to update primaries even if sampled set is empty
Tor Bug Tracker & Wiki
blackhole at torproject.org
Wed Oct 25 16:05:16 UTC 2017
#23989: entry_guards_update_all() will pretend to update primaries even if sampled
set is empty
-------------------------+-------------------------------------------------
Reporter: asn | Owner: (none)
Type: defect | Status: new
Priority: Medium | Milestone: Tor: 0.3.2.x-final
Component: Core | Version: Tor: 0.3.0.1-alpha
Tor/Tor | Keywords: tor-guard, tor-bridge, tor-client,
Severity: Normal | 030-backport, 031-backport
Actual Points: | Parent ID: #23862
Points: | Reviewer:
Sponsor: |
-------------------------+-------------------------------------------------
`entry_guards_update_all()` is used to update all the various sets of the
guard subsystem, and then make the list of primary guards.
The first list that needs to be made is the sampled set in
`sampled_guards_update_from_consensus()`. However ,that function is a NOP
if we are missing a live consensus.
The problem here is that `entry_guards_update_all()` will not notice that
the sampled set was never initialized and will happily move forward into
making the list of primary guards from a non-existent sampled set which
will fail. It will also set `gs->primary_guards_up_to_date` and other
parts of the subsystem will think that there is actually a primary guard
list and will not initialize it (e.g. `select_entry_guard_for_circuit()`).
We should probably not allow the primary guard list etc. to be done if we
failed to initialize our sampled set. Perhaps we could move the
`live_consensus_is_missing()` check from
`sampled_guards_update_from_consensus()` to `entry_guards_update_all()`.
'''I don't think that this can cause serious issues''' because we will
eventually regenerate our primary guard list when we finally fetch a live
consensus.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/23989>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list