mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-30 23:53:32 +01:00
Merge branch 'bug17772_024' into maint-0.2.4
This commit is contained in:
commit
35deb4d442
7
changes/bug17772
Normal file
7
changes/bug17772
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
o Major bugfixes (guard selection):
|
||||||
|
- Actually look at the Guard flag when selecting a new directory
|
||||||
|
guard. When we implemented the directory guard design, we
|
||||||
|
accidentally started treating all relays as if they have the Guard
|
||||||
|
flag during guard selection, leading to weaker anonymity and worse
|
||||||
|
performance. Fixes bug 17222; bugfix on 0.2.4.8-alpha. Discovered
|
||||||
|
by Mohsen Imani.
|
@ -1537,8 +1537,14 @@ router_pick_directory_server_impl(dirinfo_type_t type, int flags)
|
|||||||
if ((type & MICRODESC_DIRINFO) && !is_trusted &&
|
if ((type & MICRODESC_DIRINFO) && !is_trusted &&
|
||||||
!node->rs->version_supports_microdesc_cache)
|
!node->rs->version_supports_microdesc_cache)
|
||||||
continue;
|
continue;
|
||||||
if (for_guard && node->using_as_guard)
|
/* Don't make the same node a guard twice */
|
||||||
continue; /* Don't make the same node a guard twice. */
|
if (for_guard && node->using_as_guard) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
/* Ensure that a directory guard is actually a guard node. */
|
||||||
|
if (for_guard && !node->is_possible_guard) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
if (try_excluding &&
|
if (try_excluding &&
|
||||||
routerset_contains_routerstatus(options->ExcludeNodes, status,
|
routerset_contains_routerstatus(options->ExcludeNodes, status,
|
||||||
country)) {
|
country)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user