Skip to content

Commit

Permalink
Safer handling of sessions during authentication
Browse files Browse the repository at this point in the history
- always generate new session for login form
- always generate new session when authenticated using cookie auth

Signed-off-by: Michal Čihař <michal@cihar.com>
  • Loading branch information
nijel committed May 23, 2016
1 parent 84fbe2c commit f9d6c40
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions ChangeLog
Expand Up @@ -13,6 +13,7 @@ phpMyAdmin - ChangeLog
- issue #12219 Fix locking issues when importing SQL
- issue #12231 Avoid confusing warning when mysql extension is missing
- issue Improve handling of logout
- issue Safer handling of sessions during authentication

4.6.1 (2016-05-02)
- issue #12120 PMA_Util not found in insert_edit.lib.php
Expand Down
4 changes: 1 addition & 3 deletions libraries/common.inc.php
Expand Up @@ -731,9 +731,7 @@

if (! $auth_plugin->authCheck()) {
/* Force generating of new session on login */
if ($token_provided) {
PMA_secureSession();
}
PMA_secureSession();
$auth_plugin->auth();
} else {
$auth_plugin->authSetUser();
Expand Down
1 change: 1 addition & 0 deletions libraries/plugins/auth/AuthenticationCookie.php
Expand Up @@ -341,6 +341,7 @@ public function authCheck()
}
$GLOBALS['pma_auth_server'] = $_REQUEST['pma_servername'];
}
PMA_secureSession();
return true;
}

Expand Down

0 comments on commit f9d6c40

Please sign in to comment.