-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
make it possible to run Dialer and Listener on the same UDP socket #561
Comments
I don't understand what you want to do here and why ^^ |
This would be useful for protocols that rely on stun for NAT punchthrough. It would be awesome if this existed, yet it can be done outside of the library if quic framing is deterministic and sessions are easily identifiable with each Write() call. We already do something simillar in syncthing and kcp where we have a single UDP connection and then filter incoming stun and KCP traffic based on the signatures into virtual connections using something like https://github.com/AudriusButkevicius/pfilter. |
This will not be supported by QUIC v1, see quicwg/base-drafts#714 (comment). |
Good news. It looks like with the current new QUIC header format, this will be possible. |
Superb! Are there plans to suppprt this feature in this implementation? |
Sure, that's what this issue is there for ;) |
Do you have an idea of what needs to be done to support this? Asking in case this is a low hanging fruit that I could contribute myself without having to refactor everything and learn quic spec by heart. |
It's probably the most complicated issues we currently have. |
Given the multiplexer is now merged, would it be possible to reuse the multiplexer for mixing server and client sockets? My idea is have a type exposed:
You'd pass in It would work as follows:
|
Header parsing is currently a mess, which is blocking this issue. There are just too many different header formats at the moment... Regarding the additional |
I am trying to understand what is left to do to support this, as I suspect currently Listen part of the socket might read a packet which is meant to be delivered to a session that was acquired by Dial, essentially causing the packet to be dropped (or being interpreted as a new SYN) |
Yes, that's the problem. We currently have a |
Not sure yet how we can make this work, but it'd be a nice feature.
The text was updated successfully, but these errors were encountered: