Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support QUIC in private networks #8006

Open
akowalsk opened this issue Mar 24, 2021 · 4 comments
Open

Support QUIC in private networks #8006

akowalsk opened this issue Mar 24, 2021 · 4 comments
Labels
effort/days Estimated to take multiple days, but less than a week exp/wizard Extensive knowledge (implications, ramifications) required kind/bug A bug in existing code (including security flaws) kind/enhancement A net-new feature or improvement to an existing feature P3 Low: Not priority right now topic/libp2p Topic libp2p

Comments

@akowalsk
Copy link

Version information:

go-ipfs version: 0.8.0-ce693d7e8
Repo version: 11
System version: amd64/linux
Golang version: go1.14.15

Description:

When using a private swarm (by placing a properly formatted swarm.key file in the repo), the daemon won't listen for the QUIC protocol even when configured in Addresses. If you increase the logging level, the relevant message that appears is:

WARN swarm2 listen on /ip4/0.0.0.0/udp/4001/quic failed: no transport for protocol
WARN swarm2 listen on /ip6/::/udp/4001/quic failed: no transport for protocol

I found some reference to this being a problem in earlier releases (pre-0.6 when QUIC was redone) here. The release notes imply that QUIC is GA now and should be preferred for all connections.

Steps to replicate:

  1. Create a new repo with ipfs init
  2. Start the daemon
    The output will include "Swarm listening on /ip4/127.0.0.1/udp/4001/quic"
  3. Add a properly formatted swarm.key file to the repo.
  4. Start the daemon
    The output will not include "Swarm listening on /ip4/127.0.0.1/udp/4001/quic"
@akowalsk akowalsk added kind/bug A bug in existing code (including security flaws) need/triage Needs initial labeling and prioritization labels Mar 24, 2021
@ipfs ipfs deleted a comment from welcome bot Mar 31, 2021
@Stebalien
Copy link
Member

Support for private connections on QUIC was never finished. Work was started in libp2p/go-libp2p-quic-transport#119 but was never finished because it was never really a high priority. QUIC is important when you have a large network (no per-connection file descriptor, fast connection establishment times, etc.). Private networks are usually small enough that you can remain connected to all peers on the network without running out of file descriptors.

However, you're right. We should finish this eventually.

@Stebalien Stebalien added kind/enhancement A net-new feature or improvement to an existing feature P3 Low: Not priority right now topic/libp2p Topic libp2p and removed need/triage Needs initial labeling and prioritization labels Mar 31, 2021
@Stebalien Stebalien changed the title QUIC listener disabled when using swarm key Support QUIC in private networks Mar 31, 2021
@Stebalien Stebalien added effort/days Estimated to take multiple days, but less than a week exp/wizard Extensive knowledge (implications, ramifications) required labels Mar 31, 2021
@akowalsk
Copy link
Author

Understood. Just to add another use case to the list for this, I actually need it for NAT traversal (where nodes of the private network are behind different and independent NAT devices that do not support UPnP). Specifically, I need a UDP-based protocol (QUIC itself doesn't matter to me) so that I can use a STUN/ICE server to communicate peer connections back to each node after doing a UDP hole punch. I realize IPFS itself doesn't support STUN/ICE right now, but I can handle this out of band as long as the communication protocol uses UDP.

@Stebalien
Copy link
Member

Ah, I see. Yeah, that makes sense. FYI: libp2p/go-libp2p#1039.

@ldhios
Copy link

ldhios commented Sep 6, 2023

@akowalsk Hi, I am having the same NAT problem as you while using ipfs private network. Do you have any good solutions?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
effort/days Estimated to take multiple days, but less than a week exp/wizard Extensive knowledge (implications, ramifications) required kind/bug A bug in existing code (including security flaws) kind/enhancement A net-new feature or improvement to an existing feature P3 Low: Not priority right now topic/libp2p Topic libp2p
Projects
None yet
Development

No branches or pull requests

3 participants