K4MVR3T717

[Xampp] Google Auto Dorker

Sep 29th, 2016
1,385
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.89 KB | None | 0 0
  1. <?php
  2. /**
  3. Tu5b0l3d | IndoXploit
  4. www.indoxploit.or.id
  5. Nitip Nick ahhh :v = K4MVR3T717 | Indonesian Freedom Security
  6. **/
  7. error_reporting(0);
  8.  
  9. function save($data){
  10. $fp = @fopen("Result-dorker.html", "a") or die("cant open file");
  11. fwrite($fp, $data);
  12. fclose($fp);
  13. }
  14. $links = array();
  15. $dork = "Text input Dork!";
  16. for($i=0;$i<=1000;$i+=10){
  17. $xml = new DOMDocument('1.0', "UTF-8");
  18.  
  19. $xml->loadHTMLFile("http://www.google.com/search?q=".urlencode($dork)."&start=$i");
  20. echo "ahh";
  21.  
  22. foreach($xml->getElementsByTagName('cite') as $link) {
  23.  
  24. $su = "http://$link->nodeValue";
  25.  
  26. $ahh = parse_url($su, PHP_URL_HOST);
  27. if(in_array($ahh, $links) or preg_match("/blogspot/",$ahh)) {
  28. echo "$ahh element is in the array";
  29. }
  30. else{
  31. save("$ahh<br>");
  32. $links[] = $ahh;
  33. print_r($links);
  34. }
  35. }
  36. }
  37.  
  38.  
  39. ?>
Add Comment
Please, Sign In to add comment