Skip to content

Archive

Sessions

1 articles
Cybersecurity 01 Sep 2026 3 min read

Prevent Session Fixation During Web Authentication

Session fixation occurs when an attacker can cause a victim to authenticate while using a session identifier the attacker already knows. If the application keeps that identifier after login, the attacker may reuse it to access the newly authenticated session. The core defense is to change the session identifier whenever privilege changes. Rotate at authentication boundaries After credentials, passkeys, or another authentication factor succeeds, create a fresh unpredictable session identifier and retire the pre-authentication identifier. Apply the same principle after privilege elevation, impersonation boundaries, or other security-sensitive identity changes.