aboutsummaryrefslogtreecommitdiff
path: root/src/or/routerlist.c
diff options
context:
space:
mode:
authorteor <teor2345@gmail.com>2016-12-16 22:34:42 +1100
committerNick Mathewson <nickm@torproject.org>2017-01-13 16:49:33 -0500
commit0417dae5808ddf86aed3a9b9a6883fa8f0922d2e (patch)
treeabe901ae769502b7600ffad7546a968afce9a13f /src/or/routerlist.c
parent5227ff4aadcb41f8758d426bf8ddfb4fb2d82cdf (diff)
downloadtor-0417dae5808ddf86aed3a9b9a6883fa8f0922d2e.tar.gz
tor-0417dae5808ddf86aed3a9b9a6883fa8f0922d2e.zip
When IPv6 addresses have not been downloaded, use hard-coded address info
The microdesc consensus does not contain any IPv6 addresses. When a client has a microdesc consensus but no microdescriptor, make it use the hard-coded IPv6 address for the node (if available). (Hard-coded addresses can come from authorities, fallback directories, or configured bridges.) If there is no hard-coded address, log a BUG message, and fail the connection attempt. (All existing code checks for a hard-coded address before choosing a node address.) Fixes 20996, fix on b167e82 from 19608 in 0.2.8.5-alpha.
Diffstat (limited to 'src/or/routerlist.c')
-rw-r--r--src/or/routerlist.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/or/routerlist.c b/src/or/routerlist.c
index 6bac57d4db..043419562c 100644
--- a/src/or/routerlist.c
+++ b/src/or/routerlist.c
@@ -948,7 +948,7 @@ authority_certs_fetch_resource_impl(const char *resource,
/* If we've just downloaded a consensus from a bridge, re-use that
* bridge */
- if (options->UseBridges && node && !get_via_tor) {
+ if (options->UseBridges && node && node->ri && !get_via_tor) {
/* clients always make OR connections to bridges */
tor_addr_port_t or_ap;
/* we are willing to use a non-preferred address if we need to */