]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Fix: close intro circuit if no more intro points are usable
authorDavid Goulet <dgoulet@ev0ke.net>
Fri, 16 Jan 2015 22:43:33 +0000 (17:43 -0500)
committerDavid Goulet <dgoulet@ev0ke.net>
Mon, 19 Jan 2015 14:44:11 +0000 (09:44 -0500)
Once a NACK is received on the intro circuit, tor tries an other usable one
by extending the current circuit to it. If no more intro points are usable,
now close the circuit.

Fixes #14224

Signed-off-by: David Goulet <dgoulet@ev0ke.net>
src/or/rendclient.c

index 19a8cef1bff17a8eea0d6b91870534ff5e92e2dc..1353ee38d57c0e1be3884f176e7eca001ee0e459 100644 (file)
@@ -468,6 +468,10 @@ rend_client_introduction_acked(origin_circuit_t *circ,
       /* XXXX If that call failed, should we close the rend circuit,
        * too? */
       return result;
+    } else {
+      /* Close circuit because no more intro points are usable thus this
+       * circuit is not useful anymore. */
+      circuit_mark_for_close(TO_CIRCUIT(circ), END_CIRC_REASON_FINISHED);
     }
   }
   return 0;