Getting an IP using WebRTC

2016/10/30 code web

In the past, you had to send a ping to a server, and the server would reply with a description of how they witnessed the request. With the advent of WebRTC, you can do it within a single browser.

I'm not sure what the relationship between them is, but ICE is a mechanism whereby a browser receives a statement of potential avenues of communication with another client (the "offer"), and under normal circumstances inspects it then communicates to said client what they agree is the best way to make a connection, dodging firewalls and whatnot (the "answer"). The process is called signaling, and usually requires an old-school server to broker the connection.

Here we just scan the offers to see what kind of IPs we're advertising.

Apple of course is dragging its feet and refuses to implement it in Safari.