bug7sec

Secopey | Search vulnerability

Mar 29th, 2016
754
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 5.03 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4.         <title>Secopey | Search vulnerability</title>
  5.         <style type="text/css">
  6.         body{
  7.                 color: #3EF403;
  8.                 background-color: black;
  9.         }
  10.         input {
  11.     border: dashed 1px;
  12.     border-color: #333;
  13.     BACKGROUND-COLOR: Black;
  14.     font: 8pt Verdana;
  15.     color: #0CFF37;
  16.         }
  17.  
  18.         select {
  19.     border: dashed 1px;
  20.     border-color: #333;
  21.     BACKGROUND-COLOR: Black;
  22.     font: 8pt Verdana;
  23.     color: #0CFF37;
  24. }
  25.         </style>
  26. </head>
  27. <body>
  28. <pre style="text-align: center">
  29.                                                        
  30.   ______ ____   ____  ____ ______   ____ ___.__.
  31.  /  ___// __ \_/ ___\/  _ \\____ \_/ __ <   |  |
  32.  \___ \\  ___/\  \__(  <_> )  |_> >  ___/\___  |
  33. /____  >\___  >\___  >____/|   __/ \___  > ____|
  34.      \/     \/     \/      |__|        \/\/    
  35.  
  36. -[ search vulnerability | Shor7cut - Bug7sec Team ]-
  37. <!-- search scope vulnerability -->
  38. </pre>
  39.  
  40. <Center>
  41. <form action="" method="post">
  42. <input type="text" value="" name="url" placeholder="http://localhost/">
  43. <select name="cms">
  44.         <option value="1">Wordpress</option>
  45.         <option value="2">Joomla</option>
  46. </select>
  47. <input type="submit" name="submit" value="Scan Now!"/>
  48. </form>
  49. <pre style="text-align: left;">
  50. <?php
  51. /*
  52. Name    : Secopey | Search vulnerability
  53. Date    : 29/03/2016 03:04 PM
  54. Link    : http://facebook.com/bug7sec
  55. Link    : http://pastebin.com/u/shor7cut
  56. Author  : Shor7cut
  57. */
  58. set_time_limit(0);
  59. error_reporting(0);
  60.  
  61. class hun7ing
  62. {
  63.         function sRequesthc($url , $cms , $method , $page){
  64.         if($method == "PAGE"){        
  65.         $curl = curl_init("https://www.exploit-db.com/search/?order_by=date&order=desc&pg=".$page."&action=search&description=".$cms."");
  66.         //&platform=31
  67.         }else{
  68.         $curl = curl_init($url);        
  69.         }
  70.         curl_setopt($curl, CURLOPT_USERAGENT, "msnbot/1.0 (+http://search.msn.com/msnbot.htm)");
  71.         curl_setopt($curl, CURLOPT_FOLLOWLOCATION, true);
  72.         curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
  73.         curl_setopt($curl, CURLOPT_TIMEOUT, 30);
  74.         curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
  75.         curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
  76.         curl_setopt($curl, CURLOPT_COOKIEJAR, './temp/cookies.log');
  77.         curl_setopt($curl, CURLOPT_COOKIEFILE, './temp/cookies.log');
  78.         $data = curl_exec($curl);
  79.         return $data;
  80.         }
  81.  
  82.         function countPage($data){
  83.                 $re = "/&pg=(.*?)&/";
  84.                 preg_match_all($re, $data, $matches);
  85.                 $un = array_unique($matches[1]);
  86.                 return $un[10];
  87.         }
  88.  
  89.         function unique($udat){
  90.                 return array_unique($udat);
  91.         }
  92.  
  93.         function cms($shcid){
  94.                 switch ($shcid) {
  95.                         case '1':
  96.                                 $shc_ = array(
  97.                                         'Themes'  => '/wp-content\\/themes\\/(.*?)\\//' ,
  98.                                         'Plugins' => '/wp-content\\/plugins\\/(.*?)\\//' ,
  99.                                 );
  100.                         break;
  101.                         case '2':
  102.                                 $shc_ = array(
  103.                                         'Themes' => '/\\/templates\\/(.*?)\\//',
  104.                                         'Modules' => '/\\/modules\\/(.*?)\\//',
  105.                                         'Option' => '/.?option=(.*?)&/'
  106.                                                 );
  107.                         break;
  108.                        
  109.                         default:
  110.                         break;
  111.  
  112.                 }
  113.                                         return $shc_;
  114.         }
  115.  
  116. }
  117.  
  118.                
  119.  
  120.         if(isset($_POST['cms']) && isset($_POST['url']) && isset($_POST['submit'])){
  121.  
  122.  
  123.         $url = $_POST['url'];
  124.         $data = hun7ing::sRequesthc($url,'NULL','NULL','NULL');
  125.         echo "[#]-| Site URL -> ".htmlentities($url)." <br>";
  126.         foreach (hun7ing::cms($_POST['cms']) as $key => $value) {
  127.                 preg_match_all($value, $data, $wpThemesMatch);
  128.                 foreach (hun7ing::unique($wpThemesMatch[1]) as $key => $exco) {
  129.                         $expdbs   = hun7ing::sRequesthc("https://www.exploit-db.com/search/?order_by=date&order=desc&pg=1&action=search&text={$exco}",'NULL','NULL','NULL');
  130.                         $linkexp = "/https:\\/\\/www.exploit-db.com\\/exploits\\/(.*?)\\//";
  131.                         preg_match_all($linkexp, $expdbs, $los);
  132.                         if($los[0]){
  133.                                 echo "[+]-| Search Exploit -> $exco <br>";
  134.                         foreach ($los[0] as $key => $link) {
  135.                                 echo "    |-[DB] $link <br>";
  136.                         }
  137.  
  138.                         }else{
  139.                                 echo "[+]-| Search Exploit -> $exco <br>";
  140.                         }
  141.                         ob_flush(); flush();
  142. }
  143. }
  144.  
  145.         }
  146.  
  147.  
  148. ?>
  149. </pre>
  150. </Center>
  151. </body>
  152. </html>
Advertisement
Add Comment
Please, Sign In to add comment