[or-cvs] [tor/release-0.2.1 1/8] fetch relay descriptors from v3 authorities

arma at torproject.org arma at torproject.org
Sun May 2 22:00:29 UTC 2010


Author: Roger Dingledine <arma at torproject.org>
Date: Sat, 3 Apr 2010 21:53:29 -0400
Subject: fetch relay descriptors from v3 authorities
Commit: 0324d3b0ec6d8ee0ec24c2e93915c9aa70e1665d

---
 changes/1324-fetch-from-v3-not-v2 |    5 +++++
 src/or/directory.c                |    8 ++++++--
 2 files changed, 11 insertions(+), 2 deletions(-)
 create mode 100644 changes/1324-fetch-from-v3-not-v2

diff --git a/changes/1324-fetch-from-v3-not-v2 b/changes/1324-fetch-from-v3-not-v2
new file mode 100644
index 0000000..7026980
--- /dev/null
+++ b/changes/1324-fetch-from-v3-not-v2
@@ -0,0 +1,5 @@
+  o Major bugfixes:
+    - Directory mirrors were fetching relay descriptors only from v2
+      directory authorities, rather than v3 authorities like they should.
+      Only 2 v2 authorities remain (compared to 7 v3 authorities), leading
+      to a serious bottleneck. Bugfix on 0.2.0.9-alpha. Fixes bug 1324.
diff --git a/src/or/directory.c b/src/or/directory.c
index 4153bca..7ec97d4 100644
--- a/src/or/directory.c
+++ b/src/or/directory.c
@@ -128,6 +128,8 @@ authority_type_to_string(authority_type_t auth)
     smartlist_add(lst, (void*)"V1");
   if (auth & V2_AUTHORITY)
     smartlist_add(lst, (void*)"V2");
+  if (auth & V3_AUTHORITY)
+    smartlist_add(lst, (void*)"V3");
   if (auth & BRIDGE_AUTHORITY)
     smartlist_add(lst, (void*)"Bridge");
   if (auth & HIDSERV_AUTHORITY)
@@ -309,12 +311,14 @@ directory_get_from_dirserver(uint8_t dir_purpose, uint8_t router_purpose,
     case DIR_PURPOSE_FETCH_EXTRAINFO:
       type = EXTRAINFO_CACHE |
              (router_purpose == ROUTER_PURPOSE_BRIDGE ? BRIDGE_AUTHORITY :
-                                                        V2_AUTHORITY);
+                                                        V3_AUTHORITY);
       break;
     case DIR_PURPOSE_FETCH_V2_NETWORKSTATUS:
+      type = V2_AUTHORITY;
+      break;
     case DIR_PURPOSE_FETCH_SERVERDESC:
       type = (router_purpose == ROUTER_PURPOSE_BRIDGE ? BRIDGE_AUTHORITY :
-                                                        V2_AUTHORITY);
+                                                        V3_AUTHORITY);
       break;
     case DIR_PURPOSE_FETCH_RENDDESC:
       type = HIDSERV_AUTHORITY;
-- 
1.6.5




More information about the tor-commits mailing list