Advertisement
Mr1337Joker

Bing Dorker ( Developed By MrJoker ) - Auto CMS Checker

Aug 5th, 2016
1,600
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 3.45 KB | None | 0 0
  1. <?php
  2. print "
  3. Mini Bing orker
  4. Coded By : Mr.MaGnoM
  5. Dev By : MrJoker
  6. Facebook.com/mr.magnom2
  7. Facebook.com/1337MrJoker
  8. ";
  9. function getsource($url, $proxy) {
  10.     $curl = curl_init($url);
  11.     curl_setopt($curl, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.2) Gecko/20090729 Firefox/3.5.2 GTB5");
  12.     curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
  13.     if ($proxy) {
  14.         $proxy = explode(':', autoprox());
  15.         curl_setopt($curl, CURLOPT_PROXY, $proxy[0]);
  16.         curl_setopt($curl, CURLOPT_PROXYPORT, $proxy[1]);
  17.     }
  18.     $content = curl_exec($curl);
  19.     curl_close($curl);
  20.     return $content;
  21. }
  22.  
  23. echo "\n\t ur dork here : ";$dork=trim(fgets(STDIN,1024));
  24. $do=urlencode($dork);
  25.         //$ip="200.58.111.34";
  26.         $npage = 1;
  27.         $npages = 30000;
  28.         $allLinks = array();
  29.         $lll = array();
  30.         while($npage <= $npages) {
  31.             $x = getsource("http://www.bing.com/search?q=".$do."&first=" . $npage."&FORM=PERE4", $proxy);
  32.             if ($x) {
  33.                 preg_match_all('#<h2><a href="(.*?)" h="ID#', $x, $findlink);
  34.                 foreach ($findlink[1] as $fl) array_push($allLinks, $fl);
  35.                 $npage = $npage + 10;
  36.                 if (preg_match("(first=" . $npage . "&amp)siU", $x, $linksuiv) == 0) break;
  37.             } else break;
  38.         }
  39.         $URLs = array();
  40.         foreach($allLinks as $url){
  41.             $exp = explode("/", $url);
  42.             $URLs[] = $exp[2];
  43.         }
  44.         $array = array_filter($URLs);
  45.         $array = array_unique($array);
  46.         $sss=count(array_unique($array));
  47.                 echo"\nToTaL SiTe : ". $sss.'';
  48.  
  49.         foreach ($array as $domain) {
  50. $cms=new cms_detect();
  51. $cms->go($domain);
  52.             echo"\nhttp://".$cms->url."/";
  53.             $fp = fopen("re.html","a+");
  54.             fwrite($fp,"http://".$cms->url."/");
  55.             fclose($fp);
  56.  
  57.         }
  58. class cms_detect{
  59.     function __construct() {
  60.         $this->cms="";
  61.         $this->url="";
  62.         $this->hitindex=0;
  63.         $this->response_data = array();
  64.     }
  65.     function fetch($PATH,$KEY){
  66.         $fetch_url=$this->url.$PATH;
  67.         $fetch_data=@file_get_contents($fetch_url);
  68.         $this->response_data[$KEY]=$fetch_data;
  69.     }
  70.     function compare_hit($CMS_KEY,$DATA_KEY,$CONTENT,$HIT_VALUE){
  71.         $tmp_pos=strpos($this->response_data[$DATA_KEY],$CONTENT);
  72.         if ($tmp_pos>0){
  73.             $this->hit[$CMS_KEY]=$this->hit[$CMS_KEY]+$HIT_VALUE;
  74.         };
  75.     }
  76.     function go($URL){
  77.         $this->url=$URL;
  78.         $this->fetch('','root');
  79.         $this->fetch('administrator/','slash_administrator');
  80.         $this->fetch('node/','slash_drupal');
  81.         $this->fetch('user/login/','slash_drupal');
  82.         $this->fetch('wp-admin/','slash_wp_admin');
  83.         $this->compare_hit('joomla','slash_administrator','joomla.org',0.34);
  84.         $this->compare_hit('joomla','slash_administrator','Joomla!',0.34);
  85.         $this->compare_hit('joomla','slash_administrator','loginform',0.34);
  86.         $this->compare_hit('wordpress','slash_wp_admin','wp-login.php',0.33);
  87.         $this->compare_hit('wordpress','slash_wp_admin','wordpress',0.34);
  88.         $this->compare_hit('wordpress','root','wp-content',0.34);
  89.         $this->compare_hit('drupal','slash_drupal','sites/default',0.34);
  90.         $this->compare_hit('drupal','slash_drupal','sites',0.34);
  91.         @arsort($this->hit);
  92.         $this->cms=@key($this->hit);
  93.         $this->hitindex=@reset($this->hit);
  94.     }
  95. }
  96. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement