..a different index page for the suite. It's very easy because the only thing you need to do is change the content of default.php. I don't want to create something like hello world or..
AntiFTP uses wordlists in order to bruteforce FTP user accounts
<?php
/* Medusa Shell manager
Author: Remco Kouw
Site: http://www.hacksuite.com
Last Edit: 10-03-2015
*/
if(!defined('IN_SCRIPT')){
exit;
}
$_CONTEXT['subtitle'] = "Medusa Shell Manager";
// target files we need, so make sure they are present
$aFiles = array($_PATHS['functions_root']."/get_file_data.php",$_PATHS['functions_root']."/getfilebydir.php");
for($x=0;$x<count($aFiles);$x++){
(!IsThere($aFiles[$x]) ? include_once($_PATHS['end']) : include_once($aFiles[$x]));
}
// get files from the shell directory
$aFiles = GetFilesByDirectory($_PATHS['shell_root'],0);
if(!isset($_POST['submit'])){
// select shell form
$sSelect = "<select name=\"sShell\">\n";
$iFiles = count($aFiles);
if($iFiles>0){
for($x=0;$x<$iFiles;$x++){
// let's make the file selection menu
$sSelect .= "<option value=\"".$aFiles[$x]."\">".$aFiles[$x]."</option>\n";
}
$sSelect .= "</select>\n";
$sCode .= " <form method=\"post\">\n";
$sCode .= " <div class=\"emboss borderr5 border1pxtrans pad5 edgeglow overflw\">\n";
$sCode .= " <div class=\"embosshdrnocenter border1pxtrans pad10\">Manage your medusa shells</div>\n";
$sCode .= " <div class=\"cc_record\">\n";
$sCode .= " <div class=\"flt pad3 w150\">select shell file:</div>\n";
$sCode .= " <div class=\"flt pad3\">".$sSelect."</div>\n";
$sCode .= " </div>\n";
$sCode .= " <div class=\"clear\"></div>\n";
$sCode .= " <div class=\"cc_record\">\n";
$sCode .= " <div class=\"flt pad3\"><input type=\"hidden\" name=\"iCFG\" value=\"".$_POST['iCFG']."\" /><input type=\"submit\" name=\"submit\" value=\"Download\" /> <input type=\"submit\" name=\"submit\" value=\"Remove\" /> <input type=\"submit\" name=\"submit\" value=\"Show Source\" /></div>\n";
$sCode .= " </div>\n";
$sCode .= " <div class=\"clear\"></div>\n";
$sCode .= " </div>\n";
$sCode .= " </form>\n";
}
else{
$sCode .= "<div class=\"spacingmsg\">".$_CONTEXT['result_headers']['notice']."No shells found, you can create them <a href=\"Apps/medusa/black/shellmanager.php\">here</a></div>\n";
}
}
elseif($_POST['submit']=="Remove"){
// delete shell
$sDest = ExploitFilter($_PATHS['shell_root']."/".$_POST['sShell'],0,1);
if(!file_exists($sDest)){
$_CONTEXT['errors'][] = "Shell file doesn't exist";
include_once($_PATHS['end']);
}
$sCode .= "<div class=\"spacingmsg\">".$_CONTEXT['result_headers']['result'].(@unlink($sDest) ? "Removed shell file" : "Failed to remove shell file")."</div>";
}
elseif($_POST['submit']=="Show Source"){
// show source
$sDest = ExploitFilter($_PATHS['shell_root']."/".$_POST['sShell'],0,1);
if(!file_exists($sDest)){
$_CONTEXT['errors'][] = "Shell file doesn't exist";
include_once($_PATHS['end']);
}
$sData = @str_replace("\n","<br />\n",htmlspecialchars(file_get_contents($sDest)));
$sCode .= "<div class=\"spacingmsg\">".$_CONTEXT['result_headers']['result'].$sData."</div>";
}
elseif($_POST['submit']=="Download"){
// download
$sDest = ExploitFilter($_PATHS['shell_root']."/".$_POST['sShell'],0,1);
if(!file_exists($sDest)){
$_CONTEXT['errors'][] = "Shell file doesn't exist";
include_once($_PATHS['end']);
}
else{
header("Pragma: public");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("Content-Type: application/force-download");
header("Content-Type: application/octet-stream");
header("Content-Type: application/download");
header("Content-Disposition: attachment;filename=".basename($sDest)." ");
header("Content-Transfer-Encoding: binary ");
readfile($sDest);
exit;
}
}
else{
// invalid submission button
$_CONTEXT['errors'][] = "Specified value for submission button is invalid.";
include_once($_PATHS['end']);
}
?>