Example #1
0
    require_once $CONF[path_base] . $CONF[dir_language] . $CONF[default_language] . ".php";
    if (strlen($_SESSION[cur_lang]) > 0) {
        $CUR_LANG = $_SESSION[cur_lang];
    } else {
        $CUR_LANG = $CONF[default_language];
    }
} elseif (strlen($_SESSION[cur_lang]) > 0) {
    require_once $CONF[path_base] . $CONF[dir_language] . $_SESSION[cur_lang] . ".php";
    $CUR_LANG = $_SESSION[cur_lang];
}
// Start Logging Engine for error handling and debugging
require_once "logging.php";
//Check for Auth
if (!$_SESSION[fw_logged] && ($CONF[auth_required] == "always" || $CONF_PAGE[auth_required] == "yes" && $CONF[auth_required] == "perpage") || $_GET[from_login] == 1) {
    require_once "auth_knomos.php";
    manage_auth();
}
//Update login cookie
setcookie("knomos_login", md5(session_id()), time() + 60 * 60 * 24);
// CHECK FOR SYSTEM LOCK
if (!strstr($_SERVER[SCRIPT_NAME], "mod_document") && !strstr($_SERVER[SCRIPT_NAME], "calendar_iframe") && !strstr($_SERVER[SCRIPT_NAME], "cron_web_start")) {
    $rsml = $DB->Execute("SELECT * FROM system_lock ORDER BY id DESC");
    if ($rsml->RecordCount() > 0) {
        $sys_lock = $rsml->FetchRow();
        $datetime = $sys_lock[lock_date] . " " . $sys_lock[lock_time];
        ereg("([0-9]+)-([0-9]+)-([0-9]+) ([0-9]+):([0-9]+):([0-9]+)?", $datetime, $d1);
        $from_stamp = mktime($d1[4], $d1[5], $d1[6], $d1[2], $d1[3], $d1[1]);
        //print "time: ".time()." from_Stamp: ".$from_stamp." from-min:".($from_stamp - (60*$sys_lock[min_notify]));
        if (time() >= $from_stamp) {
            header("location: " . $CONF[url_base] . 'framework/mant_lock.php' . $wrong);
        }
Example #2
0
                $_SESSION['raw_password'] = $_POST['password'];
            }
        }
        if (isset($_SESSION['username'])) {
            $username = $_SESSION['username'];
        } else {
            $username = "";
        }
        if (isset($_SESSION['raw_password'])) {
            $raw_password = $_SESSION['raw_password'];
        } else {
            $raw_password = "";
        }
    }
    $password = _addslashes($raw_password);
    if (!manage_auth($username, $password, $raw_password)) {
        exit;
    }
} else {
    $_SESSION['acl'] = array('username' => 'none', 'pdesign' => array('none'), 'pdata' => array('none'), 'pstatus' => array('none'), 'pall' => array('none'), 'pgroup' => array('none'), 'puser' => array('none'), 'superuser' => 'Y', 'disabled' => 'N');
}
if (empty($where) && isset($_REQUEST['where'])) {
    $where = $_REQUEST['where'];
}
if ($where == 'download') {
    include esp_where($where);
    exit;
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" 
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">