]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
connection: Stop forcing some ports to prefer IPv6
authorteor <teor@torproject.org>
Fri, 13 Mar 2020 02:25:43 +0000 (12:25 +1000)
committerteor <teor@torproject.org>
Fri, 13 Mar 2020 02:28:19 +0000 (12:28 +1000)
Stop forcing all non-SOCKSPorts to prefer IPv6 exit connections.
Instead, prefer IPv6 connections by default, but allow users to change
their configs using the "NoPreferIPv6" port flag.

Fixes bug 33608; bugfix on 0.4.3.1-alpha.

changes/bug33608 [new file with mode: 0644]
src/core/mainloop/connection.c

diff --git a/changes/bug33608 b/changes/bug33608
new file mode 100644 (file)
index 0000000..0e82a8e
--- /dev/null
@@ -0,0 +1,5 @@
+  o Minor bugfixes (client IPv6):
+    - Stop forcing all non-SOCKSPorts to prefer IPv6 exit connections. Instead,
+      prefer IPv6 connections by default, but allow users to change their
+      configs using the "NoPreferIPv6" port flag.
+      Fixes bug 33608; bugfix on 0.4.3.1-alpha.
index bfd850da86b41275c731bdc9d33919670ef225a0..57b48d49f365f87bb1ad01d031b58fa3ed7cbfb8 100644 (file)
@@ -1514,10 +1514,11 @@ connection_listener_new(const struct sockaddr *listensockaddr,
     }
   }
 
+  /* Force IPv4 and IPv6 traffic on for non-SOCKSPorts.
+   * Forcing options on isn't a good idea, see #32994 and #33607. */
   if (type != CONN_TYPE_AP_LISTENER) {
     lis_conn->entry_cfg.ipv4_traffic = 1;
     lis_conn->entry_cfg.ipv6_traffic = 1;
-    lis_conn->entry_cfg.prefer_ipv6 = 1;
   }
 
   if (connection_add(conn) < 0) { /* no space, forget it */