tavimori
tavimori

Reputation: 15

Is it possible to test NAT Type in a web page only (possibly using WebRTC)?

I'm new to WebRTC and I noticed that the Web API can request a STUN server for the local public IP, and may set up an RTCDataChannel session with others.

From my understanding, using the APIs above with a Web Server and a WebRTC server, it is possible to check the local NAT type within a webpage.

But as far as I know, all existing NAT Type Checking utilities are binary tools (either command-line or standalone GUI app), so I wonder if there is such a website providing this NAT Type Checking function, or is there any technical difficulty in implementing this? (Or just nobody did this for now?)

Upvotes: 1

Views: 2808

Answers (1)

Philipp Hancke
Philipp Hancke

Reputation: 17275

https://webrtchacks.com/symmetric-nat/ describes an approach. However (speaking as the person who wrote it) why bother? The NAT type doesn't offer you useful information if you use WebRTC (and hence ICE) in the browser.

Upvotes: 1

Related Questions