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

webrtc: Figure out a way to discover webrtc-direct addresses #2592

Open
sukunrt opened this issue Oct 3, 2023 · 1 comment · May be fixed by #2593
Open

webrtc: Figure out a way to discover webrtc-direct addresses #2592

sukunrt opened this issue Oct 3, 2023 · 1 comment · May be fixed by #2593
Labels
effort/days Estimated to take multiple days, but less than a week

Comments

@sukunrt
Copy link
Member

sukunrt commented Oct 3, 2023

Currently node doesn't dial out of the UDP packet conn that it is listening on for /webrtc-direct. Because of this it cannot discover its publicly dialable address.

We find our listen address by dialing out using reuseport and then checking the observed address on identify. In webrtc-direct we never do a reuseport and so there's no way to find our listening address unless we manage to do port mapping on the router. So address discovery won't work on EC2 machines which don't have access to public IP from within the instance or UPnP like port mapping system.

@mxinden how does rust-libp2p do this address discovery?

@sukunrt sukunrt linked a pull request Oct 3, 2023 that will close this issue
@mxinden
Copy link
Member

mxinden commented Oct 4, 2023

rust-libp2p's /webrtc-direct implementation reuses the listen port for outgoing dials.

Related: currently rust-libp2p's /webrtc-direct implementation has a bug, where one can not dial without a previous listen. libp2p/rust-libp2p#4071

@MarcoPolo MarcoPolo added the effort/days Estimated to take multiple days, but less than a week label Mar 22, 2024
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
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants