Browse Source

Don't answer "/tor/networkstatus-bridges" directory requests if
the request isn't encrypted.


svn:r13175

Roger Dingledine 17 years ago
parent
commit
3d3663a123
2 changed files with 6 additions and 1 deletions
  1. 4 0
      ChangeLog
  2. 2 1
      src/or/directory.c

+ 4 - 0
ChangeLog

@@ -4,6 +4,10 @@ Changes in version 0.2.0.18-alpha - 2008-01-??
       relay, if you haven't found yourself reachable yet or if you've
       relay, if you haven't found yourself reachable yet or if you've
       decided not to advertise your dirport yet. Addresses bug 556.
       decided not to advertise your dirport yet. Addresses bug 556.
 
 
+  o Minor features:
+    - Don't answer "/tor/networkstatus-bridges" directory requests if
+      the request isn't encrypted.
+
 
 
 Changes in version 0.2.0.17-alpha - 2008-01-17
 Changes in version 0.2.0.17-alpha - 2008-01-17
   o Compile fixes:
   o Compile fixes:

+ 2 - 1
src/or/directory.c

@@ -2337,7 +2337,7 @@ directory_handle_command_get(dir_connection_t *conn, const char *headers,
         smartlist_add(items, (char*)item);
         smartlist_add(items, (char*)item);
     } else if (!current && !strcmp(url, "consensus-signatures")) {
     } else if (!current && !strcmp(url, "consensus-signatures")) {
       /* XXXX020 the spec says that we should implement
       /* XXXX020 the spec says that we should implement
-       * currrent/consensus-signatures too.  Why? */
+       * current/consensus-signatures too.  Why? -NM */
       const char *item;
       const char *item;
       if ((item=dirvote_get_pending_detached_signatures()))
       if ((item=dirvote_get_pending_detached_signatures()))
         smartlist_add(items, (char*)item);
         smartlist_add(items, (char*)item);
@@ -2620,6 +2620,7 @@ directory_handle_command_get(dir_connection_t *conn, const char *headers,
 
 
   if (options->BridgeAuthoritativeDir &&
   if (options->BridgeAuthoritativeDir &&
       options->BridgePassword &&
       options->BridgePassword &&
+      connection_dir_is_encrypted(conn) &&
       !strcmp(url,"/tor/networkstatus-bridges")) {
       !strcmp(url,"/tor/networkstatus-bridges")) {
     char *status;
     char *status;
     char decoded[64];
     char decoded[64];