IPGeo Grabber Omegle - Project

2 minute read

  2 minute read

This script allows to obtain the geolocation of the stranger in a video chat on the Omegle platform in real time through the capture of the public IP, thanks to the Peer-to-Peer communication with WebRTC that follows the web.

LEGAL NOTICE AND DISCLAIMER.

IPGeo Grabber Omegle is a script for the sole purpose of educational and research purposes for developers or end users, and may help create countermeasures for current threats. I assume NO responsibility for how you choose to use any of the executables/source code of any files provided.

Design and Purpose.

Purpose

This script is intended in an informative way to show the ease by which the public IP of anyone using this platform can be obtained by using a VPN as a primary countermeasure while using this platform.

Design, Implementation and Usage

This script uses WebRTC technology which allows us to communicate with another user in your web browser.

ip geo grabber omegle

WebRTC

So we will employ the ```RTCPeerConnection`` API which allows us to open, maintain and close a connection with another person in Omegle, when we get an Ice Candidate (ICE = Interactive Connectivity Establishment, which allows two computers to talk to each other directly (Peer-to-Peer)) what we are looking for is to parse the information associated with it by dumping it into an array.

ip geo grabber omegle

ICE Candidates

Where we will focus will be on the UDP candidates of type srflx (Server Reflexive Candidate) which are those generated by the STUN server which returns the ip address, port, status of the connectivity with the other person…, for this case we will simply get the public address of the other person.

ip geo grabber omegle

WebRTC, STUN/TURN Server

Later we will obtain the geolocation through the web IpGeolocation.io through requests using its API, for this we will need an API-Key which we can obtain by simply registering in its page.

We parse the server response to JSON and format the information we want, finally displaying it by console.

ip geo grabber omegle

Results

Usage

  • On PC: In Chrome/Opera/Mozilla, in “Settings” => “More Tools” => “Developer Tools” => “Developer Tools”, with developer tools open, we access omegle.com`, and in the “Console” tab in the developer tools area, paste all the code and hit “Enter”, Now anyone you connect with, you will be shown information from it (in real time).

  • On Android: Chrome, Using usb debugging and Chrome’s “Remote Devices” option we can inject this javascript code remotely in our device’s browser.

Follow this tutorial: https://developers.google.com/web/tools/chrome-devtools/remote-debugging?hl=es