mirror of
https://github.com/vichan-devel/vichan.git
synced 2025-02-20 20:51:50 +01:00
auth.php: check if cookie exists
This commit is contained in:
parent
ed05049777
commit
4c731ba241
@ -240,7 +240,7 @@ function check_login(bool $prompt = false): void {
|
||||
$expected_cookie_name = calc_cookie_name($is_https, $is_path_jailed, $config['cookies']['mod']);
|
||||
|
||||
// Validate session
|
||||
if (isset($expected_cookie_name)) {
|
||||
if (isset($_COOKIE[$expected_cookie_name])) {
|
||||
// Should be username:hash:salt
|
||||
$cookie = explode(':', $_COOKIE[$expected_cookie_name]);
|
||||
if (count($cookie) != 3) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user