Advertisement
Tu5b0l3d

Google Dorker Source

Jun 4th, 2016
4,088
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.37 KB | None | 0 0
  1. <?php
  2. //Tu5b0l3d -idX-
  3. //http://blog.indoxploit.or.id/2016/06/google-dorker-new.html
  4. error_reporting(0);
  5. function save($data){
  6.         $fp = @fopen("hasil.htm", "a") or die("cant open file");
  7.         fwrite($fp, $data);
  8.         fclose($fp);
  9. }
  10. $list = array();
  11. $b = 5;
  12. $dorks = "intext:IndoXploit";
  13. $dork = urlencode($dorks);
  14.     for($i=0;$i+=$b;$i++){
  15.         $kuki = rand();
  16.         echo $i;
  17.         //http://ajax.googleapis.com/ajax/services/search/web?v=1.0&hl=iw&rsz=8&q=$dork&key=$kunAPI&start=$i
  18.         $ch1 = curl_init ("https://www.google.com/search?q=$dork&btnG=Search&start=$i#q=$dork&start=$i");
  19. curl_setopt ($ch1, CURLOPT_RETURNTRANSFER, 1);
  20. curl_setopt ($ch1, CURLOPT_FOLLOWLOCATION, 1);
  21.     curl_setopt ($ch1, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 6.1; rv:32.0) Gecko/20100101 Firefox/32.0");
  22. curl_setopt ($ch1, CURLOPT_SSL_VERIFYPEER, 0);
  23. curl_setopt ($ch1, CURLOPT_SSL_VERIFYHOST, 0);
  24. curl_setopt($ch1, CURLOPT_COOKIEJAR,"$kuki.txt");
  25. curl_setopt($ch1, CURLOPT_COOKIEFILE,"$kuki.txt");
  26. $result = curl_exec ($ch1);
  27.  
  28. preg_match_all("/style=\"white-space:nowrap\"><c(.*?)\//", $result, $a);
  29. foreach($a[1] as $sitesn){
  30. $sites = explode("ite class=\"_Rm\">", $sitesn);
  31. $sulton = parse_url("http://$sites[1]", PHP_URL_HOST);
  32. if(!in_array($sulton,$list)){
  33.     $list[] = $sulton;
  34.     echo "$sulton\n";
  35.     save("$sulton<br>");
  36.    
  37.  
  38. }
  39. else{
  40.     echo "$sulton ============================>\n";
  41. }
  42. }
  43.  
  44. }
  45. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement