Symfony Serializer CSV Header Nesting Without Limit Crashes PHP
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Attack requirements
- None
- Impact type
- Denial of service
- Confidentiality · integrity · availability
- None · None · High
- Fix status
- Fixed
Attack profile from CVSS 4.0 · CNA. Fix status from CNA. Impact type from CWE-674.
Summary
Symfony's Serializer in symfony/serializer and symfony/symfony nests decoded CSV rows once per key separator in each header cell, with no limit (CWE-674). Freeing such deeply nested arrays overflows the C stack, so a 448 KB CSV body can crash the PHP process. A deep header also lets a 2 KB body allocate more than 128 MB and keep the CPU busy for 10 seconds or more. A remote attacker without privileges can trigger this through any code that decodes untrusted CSV with the Serializer.
Written with Claude Haiku 5.5 from the sources below · 2026-11-25
Description from the CNA
CsvEncoder::decode() splits each header cell on the key separator, . by default, and nests the decoded rows one level per separator, with no limit. PHP frees nested arrays recursively, so freeing data that is nested deeply enough overflows the C stack and crashes the process. With a stack of 8 MB, a CSV body of 448 KB is enough. Each row also builds all the levels of its headers again. With a deep header, a CSV body of 2 KB made of short rows allocates more than 128 MB. A body of 1 MB keeps the CPU busy for 10 seconds or more. Any code that decodes untrusted CSV with the Serializer is affected. From Symfony 7.4.0, this included every #[MapRequestPayload] argument that doesn't restrict acceptFormat, until 7.4.23 and 8.1.11 stopped decoding CSV payloads by default. CSV headers can now be nested up to 512 levels, the default depth of json_decode(). Decoding also stops when the rows go through more than 16 header levels, or create more than 4 arrays, per byte of data. A header row of up to 5 levels always fits, whatever the rows contain. Beyond these limits, decode() throws a NotEncodableValueException, which #[MapRequestPayload] turns into a 400 response.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- Yes
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| symfony | symfony/serializer | before 5.4.57; 6.0.0 to before 6.4.51; 7.0.0 to before 7.4.24; 8.0.0 to before 8.1.12 | 5.4.57, 6.4.51, 7.4.24, 8.1.12 | Patch available | CNA |
| symfony | symfony/symfony | before 5.4.57; 6.0.0 to before 6.4.51; 7.0.0 to before 7.4.24; 8.0.0 to before 8.1.12 | 5.4.57, 6.4.51, 7.4.24, 8.1.12 | Patch available | CNA |
- symfony/serializer Vendorsymfony Affected before 5.4.57; 6.0.0 to before 6.4.51; 7.0.0 to before 7.4.24; 8.0.0 to before 8.1.12 Fixed in 5.4.57, 6.4.51, 7.4.24, 8.1.12 Patch available CNA
- symfony/symfony Vendorsymfony Affected before 5.4.57; 6.0.0 to before 6.4.51; 7.0.0 to before 7.4.24; 8.0.0 to before 8.1.12 Fixed in 5.4.57, 6.4.51, 7.4.24, 8.1.12 Patch available CNA
Remediation
Upgrade symfony/serializer and symfony/symfony to 5.4.57, 6.4.51, 7.4.24 or 8.1.12, depending on the branch in use.
Written with Claude Haiku 5.5 from the sources below · 2026-11-25
- Fix · CNA symfony/serializer (Symfony) Fixed in 5.4.57, 6.4.51, 7.4.24, 8.1.12
- Fix · CNA symfony/symfony (Symfony) Fixed in 5.4.57, 6.4.51, 7.4.24, 8.1.12
Fixed in the same release
Records fixed by the same vendor advisory or release, as the CNA lists them.
- Release ·
symfony/symfony 5.4.57, 6.4.51 and 2 more versions
13 records Highest priority Priority MEDIUM 2 MEDIUM, 11 LOW
Other records, highest priority first
- TI-2026-98148 Nested short ternaries make the Symfony expression parser hangPriority MEDIUM 45
- TI-2026-98153 HttpClient lets a Proxy header choose the proxy under the CLI SAPIPriority LOW 37
- TI-2026-98145 Credentials leak to other origins on redirect in Symfony HTTP clientPriority LOW 36
- Release ·
symfony/serializer 5.4.57, 6.4.51 and 2 more versions
2 records Highest priority Priority MEDIUM 1 MEDIUM, 1 LOW
Other records, highest priority first
- TI-2026-98140 Serializer ignores #[Ignore] on discriminator-mapped classes in SymfonyPriority LOW 30
Timeline
- 2026-11-25 Threatist record created from CVE-2026-133761
- 2026-11-25 CISA SSVC decision points changed
References
More symfony vulnerabilities
- TI-2026-34283 Twig: The `spaceless` filter implicitly marks its output as safe CVSS 4.0MEDIUM 5.1
- TI-2022-07667 Code injection in Twig CVSS 3.1CRITICAL 9.8
- TI-2018-10028 Twig before 2.4.4 allows Server-Side Template Injection (SSTI) via the search search_key… CVSS 3.0CRITICAL 9.8
- TI-2022-08704 Symfony storing cookie headers in HttpCache CVSS 3.1HIGH 8.8
- TI-2026-98148 Nested short ternaries make the Symfony expression parser hang CVSS 4.0HIGH 8.7
- TI-2026-35851 Incorrect authorization in symfony CVSS 4.0HIGH 8.7
Sources
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences