How to Find and Log IP Addresses 03-25-2012, 11:57 PM
#1
This will be a quick TUT on Finding and storing IP Addresses in case you want to trace or DDOS someones Connection
First make a fake website. Use Something like 000webhost. This will be the fake site that contains a .php file that takes and stores their ip address. In some cases this is also used for security i believe.
Once you made the website, you need to make the php file. You will need Notepad or anything that can write in c++, im using notepad ++
Heres the PHP file i have written, just copy and paste and make sure it is in c++ language.
<?php
$ip = $_SERVER['REMOTE_ADDR'];
$dt = date("l dS \of F Y h:i
A");
$file=fopen("ip_log.txt","a");
$data = $ip.' '.$dt."\n";
fwrite($file, $data);
fclose($file);
header( 'Location: https://google.com') ;
?>
It should look like this after saving (notepad ++)(you can change google to any other website to redirect them to)
![[Image: phptut.jpg]](http://i1048.photobucket.com/albums/s377/TeamUnknownHF/phptut.jpg)
Next just make a txt document called ip_log
Now upload the files to your websites public folder
BAM, now anyone who visits ip is stored!
Now just go back to the ip_log.txt file to view the ips
Please Rate/Comment if this helped you a bit.
First make a fake website. Use Something like 000webhost. This will be the fake site that contains a .php file that takes and stores their ip address. In some cases this is also used for security i believe.
Once you made the website, you need to make the php file. You will need Notepad or anything that can write in c++, im using notepad ++
Heres the PHP file i have written, just copy and paste and make sure it is in c++ language.
<?php
$ip = $_SERVER['REMOTE_ADDR'];
$dt = date("l dS \of F Y h:i
A");$file=fopen("ip_log.txt","a");
$data = $ip.' '.$dt."\n";
fwrite($file, $data);
fclose($file);
header( 'Location: https://google.com') ;
?>
It should look like this after saving (notepad ++)(you can change google to any other website to redirect them to)
![[Image: phptut.jpg]](http://i1048.photobucket.com/albums/s377/TeamUnknownHF/phptut.jpg)
Next just make a txt document called ip_log
Now upload the files to your websites public folder
BAM, now anyone who visits ip is stored!
Now just go back to the ip_log.txt file to view the ips
Please Rate/Comment if this helped you a bit.
Please join my website, www.unknownhacking.net
I am really in need of some members and some HQ posters. Thanks to whoever registers.
I am really in need of some members and some HQ posters. Thanks to whoever registers.
![[+]](https://sinister.ly/images/modern/collapse_collapsed.png)