[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] When fetching rendezvous descriptors, we were willing to ask
Update of /home2/or/cvsroot/tor/src/or
In directory moria:/home/arma/work/onion/cvs/tor/src/or
Modified Files:
directory.c
Log Message:
When fetching rendezvous descriptors, we were willing to ask
v2 authorities too. And of course they did not have a copy.
Index: directory.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/directory.c,v
retrieving revision 1.367
retrieving revision 1.368
diff -u -p -d -r1.367 -r1.368
--- directory.c 1 Apr 2006 22:00:49 -0000 1.367
+++ directory.c 9 Apr 2006 00:36:15 -0000 1.368
@@ -123,7 +123,8 @@ directory_get_from_dirserver(uint8_t pur
int directconn = !purpose_is_private(purpose);
int need_v1_support = purpose == DIR_PURPOSE_FETCH_DIR ||
- purpose == DIR_PURPOSE_FETCH_RUNNING_LIST;
+ purpose == DIR_PURPOSE_FETCH_RUNNING_LIST ||
+ purpose == DIR_PURPOSE_FETCH_RENDDESC;
int need_v2_support = purpose == DIR_PURPOSE_FETCH_NETWORKSTATUS ||
purpose == DIR_PURPOSE_FETCH_SERVERDESC;
@@ -154,7 +155,7 @@ directory_get_from_dirserver(uint8_t pur
log_info(LD_DIR,
"No router found for %s; falling back to dirserver list",
which);
- rs = router_pick_trusteddirserver(1, 1, 1,
+ rs = router_pick_trusteddirserver(need_v1_support, 1, 1,
retry_if_no_servers);
if (!rs)
directconn = 0; /* last resort: try routing it via Tor */
@@ -165,7 +166,7 @@ directory_get_from_dirserver(uint8_t pur
/* Never use fascistfirewall; we're going via Tor. */
if (purpose == DIR_PURPOSE_FETCH_RENDDESC) {
/* only ask authdirservers, any of them will do */
- rs = router_pick_trusteddirserver(0, 0, 0, retry_if_no_servers);
+ rs = router_pick_trusteddirserver(1, 0, 0, retry_if_no_servers);
} else {
/* anybody with a non-zero dirport will do. Disregard firewalls. */
rs = router_pick_directory_server(1, 0, need_v2_support,