]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
exit_policy_is_general_exit is IPv4 only; it should admit it.
authorNick Mathewson <nickm@torproject.org>
Sun, 6 Mar 2011 18:16:53 +0000 (13:16 -0500)
committerNick Mathewson <nickm@torproject.org>
Sun, 6 Mar 2011 18:16:53 +0000 (13:16 -0500)
src/or/policies.c

index 0a8fd7328eade38641fb1dd4822763259d0568da..f8c36c784ba0734cbcb6dfb9e526c249cf864c8b 100644 (file)
@@ -880,6 +880,8 @@ exit_policy_is_general_exit(smartlist_t *policy)
 
   for (i = 0; i < 3; ++i) {
     SMARTLIST_FOREACH(policy, addr_policy_t *, p, {
+      if (tor_addr_family(&p->addr) != AF_INET)
+        continue; /* IPv4 only for now */
       if (p->prt_min > ports[i] || p->prt_max < ports[i])
         continue; /* Doesn't cover our port. */
       if (p->maskbits > 8)