CVE-2022-24894 is a medium-severity (CVSS 5.9) CWE-285 vulnerability in symfony/http-kernel. A fix is available for symfony/http-kernel — see the affected versions and patch details below.
Symfony storing cookie headers in HttpCache
Exploitation Status
No confirmed exploitation observed yet
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for CVE-2022-24894.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
symfony/http-kernel🐘symfony/http-kernel🐘symfony/http-kernel🐘symfony/http-kernel🐘symfony/http-kernel🐘symfony/symfony🐘symfony/symfony🐘symfony/symfony+2 moreReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Packagist packages — download data is not available via public APIs for these ecosystems.
Description
Description
The Symfony HTTP cache system acts as a reverse proxy: it caches HTTP responses (including headers) and returns them to clients.
In a recent AbstractSessionListener change, the response might now contain a Set-Cookie header. If the Symfony HTTP cache system is enabled, this header might be stored and returned to some other clients. An attacker can use this vulnerability to retrieve the victim's session.
Resolution
The HttpStore constructor now takes a parameter containing a list of private headers that are removed from the HTTP response headers.
The default value for this parameter is Set-Cookie, but it can be overridden or extended by the application.
The patch for this issue is available here for branch 4.4.
Credits
We would like to thank Soner Sayakci for reporting the issue and Nicolas Grekas for fixing it.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐘Packagist | symfony/http-kernel | ≥ 2.0.0&&< 4.4.50 | 4.4.50composer require symfony/http-kernel:^4.4.50 |
| 🐘Packagist | symfony/http-kernel | ≥ 5.0.0&&< 5.4.20 | 5.4.20composer require symfony/http-kernel:^5.4.20 |
| 🐘Packagist | symfony/http-kernel | ≥ 6.0.0&&< 6.0.20 | 6.0.20composer require symfony/http-kernel:^6.0.20 |
| 🐘Packagist | symfony/http-kernel | ≥ 6.1.0&&< 6.1.12 | 6.1.12composer require symfony/http-kernel:^6.1.12 |
| 🐘Packagist | symfony/http-kernel | ≥ 6.2.0&&< 6.2.6 | 6.2.6composer require symfony/http-kernel:^6.2.6 |
| 🐘Packagist | symfony/symfony | ≥ 2.0.0&&< 4.4.50 | 4.4.50composer require symfony/symfony:^4.4.50 |
Affected Products
symfonysensiolabsDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for symfony/http-kernel, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update symfony/http-kernel to 4.4.50 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2022-24894 is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
Frequently Asked Questions
Is CVE-2022-24894 in your dependencies?
Find it across Packagist, including transitive dependencies.