summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--index.php2
-rw-r--r--program/include/rcmail.php2
2 files changed, 3 insertions, 1 deletions
diff --git a/index.php b/index.php
index 7c2d23032..721aefc7c 100644
--- a/index.php
+++ b/index.php
@@ -97,7 +97,7 @@ if ($RCMAIL->action=='login' && $RCMAIL->task=='mail') {
else if ($_SESSION['temp'] && !empty($auth['user']) && !empty($auth['host']) && isset($auth['pass']) &&
$RCMAIL->login($auth['user'], $auth['pass'], $auth['host'])) {
// create new session ID
- unset($_SESSION['temp']);
+ rcube_sess_unset('temp');
rcube_sess_regenerate_id();
// send auth cookie if necessary
diff --git a/program/include/rcmail.php b/program/include/rcmail.php
index 45b59ae49..1443617c4 100644
--- a/program/include/rcmail.php
+++ b/program/include/rcmail.php
@@ -793,6 +793,8 @@ class rcmail
*/
public function kill_session()
{
+ foreach (array_keys($_SESSION) as $var)
+ rcube_sess_unset($var);
$_SESSION = array('language' => $this->user->language, 'auth_time' => time(), 'temp' => true);
rcmail::setcookie('sessauth', '-del-', time() - 60);
$this->user->reset();