mirror of
https://github.com/pi-hole/web.git
synced 2026-05-03 23:18:12 +01:00
set httponly to true when calling setcookie. the ini_set option above doesn't actually seem to do anything... (but not removing it just in case
Signed-off-by: Adam Warner <me@adamwarner.co.uk>
This commit is contained in:
@@ -50,7 +50,8 @@
|
||||
{
|
||||
$auth = true;
|
||||
// Refresh cookie with new expiry
|
||||
setcookie('persistentlogin', $pwhash, time()+60*60*24*7);
|
||||
// setcookie( $name, $value, $expire, $path, $domain, $secure, $httponly )
|
||||
setcookie('persistentlogin', $pwhash, time()+60*60*24*7, null, null, null, true );
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -79,7 +80,8 @@
|
||||
// Set persistent cookie if selected
|
||||
if (isset($_POST['persistentlogin']))
|
||||
{
|
||||
setcookie('persistentlogin', $pwhash, time()+60*60*24*7);
|
||||
// setcookie( $name, $value, $expire, $path, $domain, $secure, $httponly )
|
||||
setcookie('persistentlogin', $pwhash, time()+60*60*24*7, null, null, null, true );
|
||||
}
|
||||
header('Location: index.php');
|
||||
exit();
|
||||
|
||||
Reference in New Issue
Block a user