Insecure Session Management
- OWASP 2025-A07
The session of a web application is only as safe as the identifier that represents it and the cookie that carries that identifier. Rapplex examines the session cookies seen during the scan, and the URLs that were requested, for settings and values that make a session easier to steal, guess or abuse.
The checks cover the SameSite attribute, the cookie lifetime, the length and randomness of the identifier, sequences of identifiers and identifiers that travel in URLs. The Secure and HttpOnly attributes are reported by other checks.
Remediation
Generate identifiers with a cryptographically secure random generator, with at least 64 bits of entropy (128 bits is recommended), and let the framework do it.
Set
Secure,HttpOnlyandSameSite(Lax or Strict) on every session cookie.Keep sessions short and invalidate them on the server at logout, and on password and privilege changes.
Never put session identifiers into URLs. Disable URL rewriting for sessions in the application server.
References
Search Vulnerability
You may also see
- Insecure Session Management (Missing SameSite Attribute)
- Insecure Session Management (SameSite None Without Secure)
- Insecure Session Management (Weak Session Identifier)
- Insecure Session Management (Predictable Session Identifier)
- Insecure Session Management (Session Identifier in URL)
- Insecure Session Management (Excessive Cookie Lifetime)
- Insecure JSON Web Token
- Insecure Session Management