Commit 0b77e870 authored by Côme Chilliet's avatar Côme Chilliet
Browse files

Fixes #4219 Fixed expiration with new logout system

parent f028c7cb
......@@ -58,7 +58,7 @@ if (!session::global_is_set('connected')) {
$ui = session::global_get('ui');
if ($_SERVER['REMOTE_ADDR'] != $ui->ip) {
new log('security', 'login', '', array(), 'main.php called with session which has a changed IP address.');
header ('Location: index.php?message=newip');
header ('Location: index.php?signout=1&message=newip');
exit;
}
$config = session::global_get('config');
......@@ -85,7 +85,7 @@ if (session::global_get('_LAST_PAGE_REQUEST') != '') {
if ($request_time > $max_life) {
session::destroy();
new log('security', 'login', '', array(), 'main.php called with expired session - logging out');
header ('Location: index.php?message=expired');
header ('Location: index.php?signout=1&message=expired');
exit;
}
}
......@@ -166,7 +166,7 @@ if (isset($_GET['plug']) && $plist->plugin_access_allowed($_GET['plug'])) {
session::global_set('plugin_dir', $plugin_dir);
if ($plugin_dir == '') {
new log('security', 'fusiondirectory', '', array(), "main.php called with invalid plug parameter \"$plug\"");
header ('Location: index.php?message=invalidparameter&plug='.$plug);
header ('Location: index.php?signout=1&message=invalidparameter&plug='.$plug);
exit;
}
} else {
......
......@@ -61,7 +61,7 @@
{literal}
function logout()
{
document.location = 'index.php?message=expired';
document.location = 'index.php?signout=1&message=expired';
}
{/literal}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment