Browse Source

backport candidate:
When sending destroy cells from a circuit's origin, don't include
the reason for tearing down the circuit. The spec says we didn't,
and now we actually don't. Reported by lodger. [Bugfix on 0.1.2.x]


svn:r10790

Roger Dingledine 17 years ago
parent
commit
9bf23e0598
2 changed files with 8 additions and 5 deletions
  1. 5 2
      ChangeLog
  2. 3 3
      src/or/circuitlist.c

+ 5 - 2
ChangeLog

@@ -70,11 +70,14 @@ Changes in version 0.2.0.3-alpha - 2007-??-??
   o Minor bugfixes (guard nodes):
     - If there's a never-before-connected-to guard node in our list,
       never choose any guards past it. This way we don't expand our
-      guard list unless we need to. [Bugfix in 0.1.2.x]
+      guard list unless we need to. [Bugfix on 0.1.2.x]
 
   o Security fixes (BSD natd support):
-    - Fix a possible buffer overrun when using BSD natd support.  Bug found
+    - Fix a possible buffer overrun when using BSD natd support. Bug found
       by croup.
+    - When sending destroy cells from a circuit's origin, don't include
+      the reason for tearing down the circuit. The spec says we didn't,
+      and now we actually don't. Reported by lodger. [Bugfix on 0.1.2.x]
 
 
 Changes in version 0.2.0.2-alpha - 2007-06-02

+ 3 - 3
src/or/circuitlist.c

@@ -958,9 +958,9 @@ _circuit_mark_for_close(circuit_t *circ, int reason, int line,
                file, line, circ->purpose);
     }
     reason = END_CIRC_REASON_NONE;
-  } else if (CIRCUIT_IS_ORIGIN(circ) && reason < _END_CIRC_REASON_MIN) {
-    /* We don't send reasons when closing circuits at the origin, but we want
-     * to track them anyway so we can give them to the controller. */
+  }
+  if (CIRCUIT_IS_ORIGIN(circ)) {
+    /* We don't send reasons when closing circuits at the origin. */
     reason = END_CIRC_REASON_NONE;
   }