Advertisement
Guest User

000webhost BruteForce

a guest
Nov 25th, 2018
275
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.58 KB | None | 0 0
  1. <?php
  2. //===========CopyRight nih Tolo ajg Bangsd Jangan Diganti=============
  3. //@Author : Fansa (IndoSec)
  4. //@Kegunaan : Gaguna sumpah, Cuman 000webhost BruteForce
  5. echo "Username : ";
  6. $user = trim(fgets(STDIN, 1024));
  7. echo "Password : ";
  8. $passwd = trim(fgets(STDIN, 1024));
  9. //===========CopyRight nih Tolo ajg Bangsd Jangan Diganti=============
  10.  
  11. //===========REQUEST METHOD=============
  12. $data = '{"action":"login","username":"'.$user.'","password":"'.$passwd.'"}';
  13. $ch = curl_init();
  14. curl_setopt($ch, CURLOPT_POST, true);
  15. curl_setopt($ch, CURLOPT_URL, 'https://files.000webhost.com/handler.php?action=login');
  16. curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
  17. curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  18. curl_setopt($ch, CURLOPT_HEADER, 0);
  19. curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json'));
  20. $res = curl_exec($ch);
  21. //===========REQUEST METHOD=============
  22.  
  23. //===========GET TITLE / Opsional=============
  24. $ch2 = curl_init();
  25. curl_setopt($ch2, CURLOPT_URL, 'https://files.000webhost.com/');
  26. curl_setopt($ch2, CURLOPT_RETURNTRANSFER, 1);
  27. curl_setopt($ch2, CURLOPT_HEADER, 0);
  28. $res2 = curl_exec($ch2);
  29. //===========GET TITLE / Opsional=============
  30.  
  31. //===========Info=============
  32. preg_match('/<title>(.*?)<\/title>/',$res2,$title);
  33. echo $title[1]."<br>";
  34. if (preg_match('/true/',$res)) {
  35. preg_match('/<title>(.*?)<\/title>/',$res,$f);
  36. echo "Sukses Login...<br><br>Response";
  37. echo "<br>=========================<br>";
  38. print_r($res);
  39. echo "<br>=========================<br>";
  40. } else {
  41. echo "Gagal Login Bos...<br>";
  42. }
  43. //===========Info=============
  44. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement