Skip to main content

discover

Function discover 

Source
pub async fn discover(sock: &UdpSocket) -> NatDiscovery
Expand description

Query every STUN server from sock and classify what we see.

sock must be bound and non-blocking, and must be the same socket the QUIC server will go on to use — that is the whole point. The socket is duplicated for the duration of the call; the original is never touched.