Fix phpMyAdmin logout: proper SignonSession destruction (issue #1680)

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
master3395
2026-02-14 22:20:26 +01:00
parent e3945705f0
commit a5b5f87d27

View File

@@ -32,11 +32,14 @@ try {
echo '<script>document.getElementById("redirectForm").submit();</script>';
} else if (isset($_POST['logout']) || isset($_GET['logout'])) {
session_name(PMA_SIGNON_SESSIONNAME);
@session_start();
$_SESSION = array();
$params = session_get_cookie_params();
setcookie(session_name(), '', time() - 86400, $params["path"], $params["domain"], $params["secure"], $params["httponly"]);
session_destroy();
header('Location: /base/');
return;
exit;
} else if (isset($_POST['password'])) {
session_name(PMA_SIGNON_SESSIONNAME);