Prop 312: 3.2.7. Automatically Enable an IPv6 ORPort
After we implement #33233 (moved), relays (and bridges) should try to open an IPv6 ORPort.
The ORPort should be opened on the port configured in the relay's ORPort torrc option. Relay operators can use the IPv4Only and IPv6Only options to configure different ports for IPv4 and IPv6.
If the ORPort is auto-detected, there will not be any specific bind address. (And the detected address may actually be on a NAT box, rather than the local machine.) Therefore, relays should attempt to bind to all IPv4 and IPv6 addresses (or all interfaces).
Some operating systems expect applications to bind to IPv4 and IPv6 addresses using separate API calls. Others don't support binding only to IPv4 or IPv6, and will bind to all addresses whenever there is no specified IP address (in a single API call). Tor should support both styles of networking API.
In particular, if binding to all IPv6 addresses fails, relays should still try to discover their public IPv6 address, and check the reachability of that address. Some OSes may not support the IPV6_V6ONLY flag, but they may instead bind to all addresses at runtime. (The tor install may also have compile-time / runtime flag mismatches.)
See proposal 312, section 3.2.7, IPv6 ORPort part: https://gitweb.torproject.org/torspec.git/tree/proposals/312-relay-auto-ipv6-addr.txt#n540
Once this ticket is implemented, we should test the different IPv4/IPv6 configs listed in #33235 (moved).