F2 · cookie-flags
Keep the login cookie on HTTPS
- What it means
- The session cookie is set without the Secure flag. Adding it keeps the cookie on encrypted connections, so signed-in sessions stay private, even on public Wi-Fi.
- Evidence
Set-Cookie: PHPSESSID=…; path=/ ↑ no Secure, no HttpOnly- Expected
Set-Cookie: PHPSESSID=…; path=/; Secure; HttpOnly; SameSite=Lax- Fix
- Add the Secure and HttpOnly flags (and SameSite=Lax) to session cookies. In PHP: session.cookie_secure = 1 and session.cookie_httponly = 1.