question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

No IPv6 support in uTP/DHT

See original GitHub issue

I was trying out Dat and noticed that IPv6 is not used to reach peers. This pretty seriously limits its usefulness for me, so I looked around the internals a bit. On a high level, I think the following changes would be needed in discovery-swarm to fix this:

  • Create separete IPv4 and IPv6 uTP sockets.
  • Run separate instances of bittorrent-dht for IPv4 and IPv6 on each socket (technically these could be merged, but makes the implementation a lot more complex for relatively little benefit).
  • Hide the distinction from higher layers (discovery-channel and up). It seems that this would happen pretty much automagically due to the event architecture.

On the lower levels, looks like this needs:

  • Support for binding IPv6 sockets in utp-native. Seems like a minor change, libutp already has support so just needs selecting the right libuv functions based on the input address.
  • Support for BEP-32 in bittorrent-dht and the k-rpc modules. A bit of work, but BEP-32 is pretty simple, and with DHT instances handling a single socket this shouldn’t cause any major restructuring.
  • dns-discovery: no idea, not going to go there for now, would continue using the current (IPv4) socket as before.

I may have some time to work on this in the near future. Does the approach sound reasonable?

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:2
  • Comments:8 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
RangerMauvecommented, Apr 1, 2019

@vuori I’m going to be doing some stability work on hyperswarm, I’ll see if I can put in IPv6 support in my spare time.

1reaction
vuoricommented, Mar 30, 2019

I’m not familiar with i2p. If you mean IPv6, it turned out that the rabbit hole went a bit too deep for a weekend project, so the issue has been on the shelf.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Postfix IPv6 Support
Postfix versions before 2.6 do not support DNSBL (real-time blackhole list) lookups for IPv6 client IP addresses. IPv6 does not have class A,...
Read more >
Utah Telecom Redefines Perception of City-Operated Service ...
In a perfect scenario, Perry would simply invest in new IPv6 technology, but the city didn't have the time nor budget for such...
Read more >
IPv6 Still Gets No Respect in the United States - eWeek
Lightman ran through the usual technical arguments for IPv6 adoption, including its greater supply of Internet addresses, improved configuration ...
Read more >
Internet Protocol Version 6: IPv6 for Consumers
What is IPv6? In order to connect devices over the Internet, each device must have an Internet protocol (IP) address. The current IP...
Read more >
IPv6 on Campus | Service Portal | University of Twente
A comparable protocol is also available for IPv6 to dynamically allocate IPv6 address to devices: DHCPv6. The UT network, however, does not use ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found