release 1.2.4
This commit is contained in:
@@ -58,28 +58,19 @@ function getclientip() {
|
||||
}
|
||||
|
||||
if (isset($_POST['logout'])) {
|
||||
$_SESSION = array();
|
||||
session_destroy();
|
||||
if($_SERVER['HTTPS'] == "on") {
|
||||
header("Location: https://".$_SERVER['HTTP_HOST'].rtrim(dirname($_SERVER['PHP_SELF']), '/\\'));
|
||||
} else {
|
||||
header("Location: http://".$_SERVER['HTTP_HOST'].rtrim(dirname($_SERVER['PHP_SELF']), '/\\'));
|
||||
}
|
||||
rem_session_ts3($rspathhex);
|
||||
header("Location: //".$_SERVER['HTTP_HOST'].rtrim(dirname($_SERVER['PHP_SELF']), '/\\'));
|
||||
exit;
|
||||
}
|
||||
|
||||
if (!isset($_SESSION['username']) || $_SESSION['username'] != $webuser || $_SESSION['password'] != $webpass || $_SESSION['clientip'] != getclientip()) {
|
||||
if($_SERVER['HTTPS'] == "on") {
|
||||
header("Location: https://".$_SERVER['HTTP_HOST'].rtrim(dirname($_SERVER['PHP_SELF']), '/\\'));
|
||||
} else {
|
||||
header("Location: http://".$_SERVER['HTTP_HOST'].rtrim(dirname($_SERVER['PHP_SELF']), '/\\'));
|
||||
}
|
||||
if (!isset($_SESSION[$rspathhex.'username']) || $_SESSION[$rspathhex.'username'] != $webuser || $_SESSION[$rspathhex.'password'] != $webpass || $_SESSION[$rspathhex.'clientip'] != getclientip()) {
|
||||
header("Location: //".$_SERVER['HTTP_HOST'].rtrim(dirname($_SERVER['PHP_SELF']), '/\\'));
|
||||
exit;
|
||||
}
|
||||
|
||||
require_once('nav.php');
|
||||
|
||||
if (isset($_POST['changepw']) && $_SESSION['username'] == $webuser && $_SESSION['password'] == $webpass && $_SESSION['clientip'] == getclientip()) {
|
||||
if (isset($_POST['changepw']) && $_SESSION[$rspathhex.'username'] == $webuser && $_SESSION[$rspathhex.'password'] == $webpass && $_SESSION[$rspathhex.'clientip'] == getclientip()) {
|
||||
$newpass = password_hash($_POST['newpwd1'], PASSWORD_DEFAULT);
|
||||
if (!password_verify($_POST['oldpwd'], $webpass)) {
|
||||
$err_msg = $lang['wichpw1']; $err_lvl = 3;
|
||||
|
||||
Reference in New Issue
Block a user