platformcosmo/Tor-IP-Addresses

IPv6 exitnodes

Closed this issue · 1 comments

I wonder if is it possible to define ExitNodes with IPv6 in torrc?

for the IPv4, it is enough to define as, for instance ExitNodes 222.222.222.222.

But not possible with IPv6?

Best regards

Address representation

The 128 bits of an IPv6 address are represented in 8 groups of 16 bits each. Each group is written as four hexadecimal digits (sometimes called hextets[37][38] or more formally hexadectets[39] and informally a quibble or quad-nibble[39]) and the groups are separated by colons (:). An example of this representation is 2001:0db8:0000:0000:0000:ff00:0042:8329.

For convenience and clarity, the representation of an IPv6 address may be shortened with the following rules:

One or more [leading zeros](https://en.wikipedia.org/wiki/Leading_zero) from any group of hexadecimal digits are removed, which is usually done to all of the leading zeros. For example, the group 0042 is converted to 42.
Consecutive sections of zeros are replaced with two colons (::). This may only be used once in an address, as multiple use would render the address indeterminate. [RFC](https://en.wikipedia.org/wiki/RFC_(identifier)) [5952](https://datatracker.ietf.org/doc/html/rfc5952) requires that a double colon not be used to denote an omitted single section of zeros.[[40]](https://en.wikipedia.org/wiki/IPv6#cite_note-rfc5952sec422-40)

An example of application of these rules:

Initial address: 2001:0db8:0000:0000:0000:ff00:0042:8329.
After removing all leading zeros in each group: 2001:db8:0:0:0:ff00:42:8329.
After omitting consecutive sections of zeros: 2001:db8::ff00:42:8329.

The loopback address 0000:0000:0000:0000:0000:0000:0000:0001 is defined in RFC 5156 and is abbreviated to ::1 by using both rules.

As an IPv6 address may have more than one representation, the IETF has issued a proposed standard for representing them in text.[41]

Because IPv6 addresses contain colons, and URLs use colons to separate the host from the port number, RFC2732[42] specifies that an IPv6 address used as the host-part of a URL should be enclosed in square brackets, e.g. http://[2001:db8:4006:812::200e] or http://[2001:db8:4006:812::200e]:8080/path/page.html.

Ref: https://en.wikipedia.org/wiki/IPv6