tor/src/feature
David Goulet 6a0763cd66 guard: Ignore marked for close circuit when changing state to open
When we consider all circuits in "waiting for guard" state to be promoted to
an "open" state, we were considering all circuits, even the one marked for
close.

This ultiamtely triggers a "circuit_has_opened()" called on the circuit that
is marked for close which then leads to possible undesirable behaviors within
a subsystem.

For instance, the HS subsystem would be unable to find the authentication key
of the introduction point circuit leading to a BUG() warning and a duplicate
mark for close on the circuit.

This commit also adds a unit test to make sure we never select marked for
close circuits when upgrading its guard state from waiting for guard to open.

Fixes #30871

Signed-off-by: David Goulet <dgoulet@torproject.org>
2019-06-19 07:41:45 -04:00
..
api Run "make autostyle." 2019-06-05 09:33:35 -04:00
client guard: Ignore marked for close circuit when changing state to open 2019-06-19 07:41:45 -04:00
control Run "make autostyle." 2019-06-05 09:33:35 -04:00
dirauth Merge remote-tracking branch 'tor-github/pr/988' into maint-0.4.0 2019-06-05 16:22:52 -04:00
dircache Run "make autostyle." 2019-06-05 09:33:35 -04:00
dirclient Run "make autostyle." 2019-06-05 09:33:35 -04:00
dircommon Run "make autostyle." 2019-06-05 09:33:35 -04:00
dirparse Merge branch 'bug30781_040' into bug30781_master 2019-06-06 09:57:31 +10:00
hibernate Run "make autostyle." 2019-06-05 09:33:35 -04:00
hs Merge remote-tracking branch 'tor-github/pr/1039' into maint-0.4.0 2019-06-05 16:13:53 -04:00
hs_common Run "make autostyle." 2019-06-05 09:33:35 -04:00
keymgt Run "make autostyle." 2019-06-05 09:33:35 -04:00
nodelist Run "make autostyle." 2019-06-05 09:33:35 -04:00
relay Run "make autostyle." 2019-06-05 09:33:35 -04:00
rend Revert "hs: Implement a helper to repurpose a circuit" 2019-06-05 11:38:01 -07:00
stats Run "make autostyle." 2019-06-05 09:33:35 -04:00