CVE-2022-24895
Symfony vulnerable to Session Fixation of CSRF tokens
Also known as BIT-symfony-2022-24895, GHSA-3gv2-29qc-v67m
Mitigation
- Upgrade symfony/security-bundle to one of 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6 (or later in the same release line).
- Upgrade symfony/symfony to one of 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6 (or later in the same release line).
Who should check
- Projects that depend on Packagist package symfony/security-bundle (>= 2.0.0, < 4.4.50)
- Projects that depend on Packagist package symfony/symfony (>= 2.0.0, < 4.4.50)
- Anyone running symfony >= 2.0.0, < 4.4.50; >= 5.0.0, < 5.4.20; >= 6.0.0, < 6.0.20; >= 6.1.0, < 6.1.12; >= 6.2.0, < 6.2.6
Vulnerability facts
- Affected
- symfony/security-bundle >= 2.0.0, < 4.4.50; symfony/symfony >= 2.0.0, < 4.4.50
- Fixed in
- 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Remote, no login needed
- CVSS
- 6.3 (v3.1, CNA)CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:LOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Network
- Attack complexity: Low
- Privileges required: None
- User interaction: Required
- Scope: Unchanged
- Confidentiality impact: Low
- Integrity impact: Low
- Availability impact: Low
- EPSS
- 0.90% chance of exploitation in 30 days (percentile 57, 2026-11-26)
- CWE
- CWE-384
- Modified
Description
Symfony is a PHP framework for web and console applications and a set of reusable PHP components. When authenticating users Symfony by default regenerates the session ID upon login, but preserves the rest of session attributes. Because this does not clear CSRF tokens upon login, this might enables same-site attackers to bypass the CSRF protection mechanism by performing an attack similar to a session-fixation. This issue has been fixed in the 4.4 branch.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Packagist symfony/security-bundle | >= 2.0.0, < 4.4.50 | 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6 | osv |
| Packagist symfony/symfony | >= 2.0.0, < 4.4.50 | 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6 | osv |
| symfony | >= 2.0.0, < 4.4.50; >= 5.0.0, < 5.4.20; >= 6.0.0, < 6.0.20; >= 6.1.0, < 6.1.12; >= 6.2.0, < 6.2.6 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2022-24895. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2022-24895.md Affected: symfony/security-bundle >= 2.0.0, < 4.4.50; symfony/symfony >= 2.0.0, < 4.4.50 Fixed in: 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6 Steps: 1. Search this machine and project for symfony/security-bundle (Packagist), symfony/symfony (Packagist), symfony: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
Vendor advisories
Patches
Other
- https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/security-bundle/CVE-2022-24895.yaml
- https://lists.debian.org/debian-lts-announce/2023/07/msg00014.html
- https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/symfony/CVE-2022-24895.yaml
- https://github.com/symfony/symfony
- https://symfony.com/cve-2022-24895
FAQ
Is CVE-2022-24895 being exploited?
There is no confirmed exploitation: CVE-2022-24895 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.90% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2022-24895?
Medium: CVSS 6.3 (v3.1, scored by CNA). Remote, no login needed. A user has to take an action, such as opening a link, for the attack to work.
Which versions are affected by CVE-2022-24895?
symfony/security-bundle >= 2.0.0, < 4.4.50; symfony/symfony >= 2.0.0, < 4.4.50.
Is there a fix for CVE-2022-24895?
Yes. Fixed in 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6. Upgrade symfony/security-bundle to one of 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6 (or later in the same release line). Upgrade symfony/symfony to one of 4.4.50, 5.4.20, 6.0.20, 6.1.12, 6.2.6 (or later in the same release line).
How do I check if I'm affected by CVE-2022-24895?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.