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

fix(netcheck): Do not read from main Conn sockets #1017

Merged
merged 1 commit into from
May 16, 2023

Conversation

flub
Copy link
Contributor

@flub flub commented May 15, 2023

The get_report function is passed the primary Conn sockets so they can
be used to send STUN messages from. However these sockets should not
be read from directly, Conn already passes through the STUN payloads.
Reading from them directly will lose packets in Conn.

When the sockets are not passed in however we should create them
ourselves, and read from them. The payloads are now received by the
actor in the same way as otherwise, removing a lot of Option<>s.

The get_report function is passed the primary Conn sockets so they can
be used to send STUN messages from.  However these sockets should not
be read from directly, Conn already passes through the STUN payloads.
Reading from them directly will lose packets in Conn.

When the sockets are not passed in however we should create them
ourselves, and read from them.  The payloads are now received by the
actor in the same way as otherwise, removing a lot of Option<>s.
@flub flub merged commit 5e997a4 into x-hp May 16, 2023
@flub flub deleted the flub-hp-netcheck-no-recv-main-socks branch May 16, 2023 09:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants