Tor Ipv6-Patch
Marcus Wolschon - Wolschon Softwaredesign
Marcus at Wolschon.biz
Tue Dec 4 08:23:25 UTC 2007
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hello Nick,
Nick Mathewson schrieb:
> - You're right that the preferred way to store addresses that could be
> either IPv4 or IPv6 is indeed with tor_addr_t. (Thanks for the
> reminder, BTW: I fixed tor_addr_t to be a tagged union of in_addr and
> in6_addr, not of sockaddr_in and sockaddr_in6.)
do you want to do the refactoring to use tor_address_t or shall I?
So we need a pair of tor_address_t and int socket_family. Wouldn't it
be better to have the socket_family in a struct with the tor_address_t
- -union? That way it would probably be a drop-in -replacement for the
32bit-addresses.
> - Generally speaking, we try to avoid duplicated "cut and paste" code;
> it makes it hard to be sure that we can update all instances of the
> original code path. (connection_or_init_conn_from_address6, for
> example, is almost exactly the same as the existing
> connection_init_conn_from_address.)
I tried to do if-then where it would not double the size of
the method. With tor_address_t this will probably be needed in
far less places.
>
> - For example, this patch includes
> lots of log cleanups that make the logs say "hidden service" instead
> of "service". That's a cleanup, and that can go into 0.2.0.x on its
> own, but it doesn't seem to be dependent much on the rest of the
> patch.
Yes, I changed that log-lined during debugging, so I could easily grep
in the debug-log while it scrolls by.
> Also, the different functional changes could probably be
> separated.
The ipv6-socks-listen is just a few lines (since it already does
ipv4+AF_UNIX) and depends on the infrastructure the ipv6-hidden-
services need.
PS:
Is there already a spec for the changes to the protocoll needed to
fully support ipv6?
* determining if a node has ipv6-connectivity (not just ipv6-support
in the ip-stack)
* asking directory-servers with a bitmask or similar of the
socket-families you support
* adressing nodes that have multiple (types of) addresses. (probably
can be ignored and theated as 2 nodes for quite a while)
* changing the protocoll to have a socket-family and space for larger
addresses.
Marcus
- --
Marcus Wolschon
Wolschon Softwaredesign und Beratung
UStID: DE238951181
Marcus at Wolschon.biz
+49 177/6272871 (m-a-r-c-u-s-1)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFHVQ59f1hPnk3Z0cQRAuhbAJ9YZXDVC9v7n5pdgpDlUfF5E8TKKQCgwwIT
/OaM8hbJyGyFe2SQgX/5tt8=
=Fii9
-----END PGP SIGNATURE-----
More information about the tor-dev
mailing list