]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Stop allowing hibernating servers to be "stable" or "fast".
authorRoger Dingledine <arma@torproject.org>
Tue, 13 Mar 2007 01:59:09 +0000 (01:59 +0000)
committerRoger Dingledine <arma@torproject.org>
Tue, 13 Mar 2007 01:59:09 +0000 (01:59 +0000)
This is what I meant to do in r9690 but didn't actually do.

svn:r9808

ChangeLog
doc/spec/dir-spec.txt
src/or/dirserv.c

index 50f5a5a4f58bfe9bcd552ec5da19b27365d71860..554f1a8bb9d70b77ea702569fc8d63b18952a075 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -32,6 +32,9 @@ Changes in version 0.2.0.1-alpha - 2007-??-??
       try to use \ consistently on windows and / consistently on unix: it
       makes the log messages nicer.
 
+  o Minor bugfixes:
+    - Stop allowing hibernating servers to be "stable" or "fast".
+
 
 Changes in version 0.1.2.10-rc - 2007-03-07
   o Major bugfixes (Windows):
index 727349acb1162f3c15a12e0cb2139f3dcb05af4f..bd3d57a34d8945bddbba83c25c76109eb1749a12 100644 (file)
@@ -425,6 +425,9 @@ $Id$
    authorities MAY do things differently, so long as clients keep working
    well.  Clients MUST NOT depend on the exact behaviors in this section.)
 
+   In the below definitions, a router is considered "active" if it is
+   running, valid, and not hibernating.
+
    "Valid" -- a router is 'Valid' if it is running a version of Tor not
    known to be broken, and the directory authority has not blacklisted
    it as suspicious.
@@ -441,20 +444,19 @@ $Id$
    "Running" -- A router is 'Running' if the authority managed to connect to
    it successfully within the last 30 minutes.
 
-   "Stable" -- A router is 'Stable' if it is running, valid, not
-   hibernating, and either its uptime is at least the median uptime for
-   known running, valid, non-hibernating routers, or its uptime is at
-   least 30 days. Routers are never called stable if they are running
-   a version of Tor known to drop circuits stupidly.  (0.1.1.10-alpha
-   through 0.1.1.16-rc are stupid this way.)
+   "Stable" -- A router is 'Stable' if it is active, and either its
+   uptime is at least the median uptime for known active routers, or
+   its uptime is at least 30 days. Routers are never called stable if
+   they are running a version of Tor known to drop circuits stupidly.
+   (0.1.1.10-alpha through 0.1.1.16-rc are stupid this way.)
 
-   "Fast" -- A router is 'Fast' if its bandwidth is in the top 7/8ths for
-   known running, valid routers.
+   "Fast" -- A router is 'Fast' if it is active, and its bandwidth is
+   in the top 7/8ths for known active routers.
 
    "Guard" -- A router is a possible 'Guard' if it is 'Stable' and its
-   bandwidth is above median for known running, valid routers.  If the total
-   bandwidth of Running Valid non-BadExit Exit servers is less than one third
-   of the total bandwidth of all Running Valid servers, no Exit is listed as
+   bandwidth is above median for known active routers. If the total
+   bandwidth of active non-BadExit Exit servers is less than one third
+   of the total bandwidth of all active servers, no Exit is listed as
    a Guard.
 
    "Authority" -- A router is called an 'Authority' if the authority
index cc85d090f6df7c71d0bb24b76d81b6877e4aeb57..3e7dad01c4150f0095926ccaa9e8013e28aa093f 100644 (file)
@@ -1629,9 +1629,11 @@ generate_v2_networkstatus(void)
         tor_version_as_new_as(ri->platform,"0.1.1.10-alpha") &&
         !tor_version_as_new_as(ri->platform,"0.1.1.16-rc-cvs");
       int f_stable = ri->is_stable =
+        router_is_active(ri, now) &&
         !dirserv_thinks_router_is_unreliable(now, ri, 1, 0) &&
         !unstable_version;
       int f_fast = ri->is_fast =
+        router_is_active(ri, now) &&
         !dirserv_thinks_router_is_unreliable(now, ri, 0, 1);
       int f_running = ri->is_running; /* computed above */
       int f_authority = router_digest_is_trusted_dir(