[VIDEO] How to Get IP and Location From Facebook/Twitter/G+/Instagram User

 

First of all, we have to clearify that It’s not possible to get someone’s IP directly! You have to communicate with your target and use Social Engineering techniques to make your victim click on URL you sent to victim.

Ok, this will be done in PHP, so It’s good to know basics of PHP, you can learn it in 30 minutes!

Before PHP programming you will have to make new database called ipdb with table named ips and 2 columns (id and ip). id need to have A_I checked (auto incresement). Once you’re done you need to type your MySQL database login info.

Let’s get started with code.

<?php
//Test if it is a shared client
if (!empty($_SERVER['HTTP_CLIENT_IP'])){
 $ip=$_SERVER['HTTP_CLIENT_IP'];
//Is it a proxy address
}elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])){
 $ip=$_SERVER['HTTP_X_FORWARDED_FOR'];
}else{
 $ip=$_SERVER['REMOTE_ADDR'];
}

$dbLink = mysqli_connect('localhost', 'root', '', 'ipdb');
$sql = "INSERT INTO ips(ip) VALUES ('$ip')";
$dbQuery = mysqli_query($dbLink, $sql);

?>

"$_SERVER['REMOTE_ADDR'] may not actually contain real client IP addresses, as it will give you a proxy address for clients connected through a proxy, for example. That may well be what you really want, though, depending what your doing with the IPs. Someone’s private RFC1918 address may not do you any good if you’re say, trying to see where your traffic is originating from, or remembering what IP the user last connected from, where the public IP of the proxy or NAT gateway might be the more appropriate to store.”

That’s it for this tutorial, If you want I can also make video tutorial, let me know in the comments!

9 Comments

  • Some guy... Reply

    March 2, 2016 at 8:30 pm

    Tutorial will be good Luka, but this is much too, thanks.

    • Luka Reply

      March 2, 2016 at 9:03 pm

      Thank You! I will do video tomorrow! I’m too tired for anything right now.

  • Jeremy Reply

    March 2, 2016 at 8:39 pm

    Can I pay someone to do this for me? As I’m not the most tech savvy person. But have some creep stalking and threatening me and my family over Instagram.

    • Luka Reply

      March 2, 2016 at 9:02 pm

      It happens and we have experience with that! You can contact us at admin[at]safenull.com

      • Alessandro Reply

        March 6, 2016 at 11:00 am

        Luka jesi li iz Hrvatske???

        • Luka Reply

          March 6, 2016 at 1:34 pm

          Jesam!
          Pozdrav iz Bjelovara 🙂

        • Luka Reply

          March 6, 2016 at 1:34 pm

          Jesam!
          Pozdrav iz Bjelovara 🙂

  • Makara Reply

    March 2, 2016 at 9:50 pm

    I want to see your video tutorial

  • walid Reply

    March 2, 2016 at 10:40 pm

    good job 🙂

Leave a Comment

Login

Welcome! Login in to your account

Remember me Lost your password?

Don't have account. Register

Lost Password

Register