Symfony YAML Component Parser Catastrophic Backtracking Vulnerability in Cleanup Method

Vulnerability

A denial-of-service vulnerability has been identified in the Symfony YAML component's parser. The issue arises in the `Parser::cleanup()` method, which uses regular expressions with overlapping quantifiers to clean up YAML directives, comments, and document markers. This flaw allows specially crafted input to cause the parsing process to hang indefinitely. The vulnerability affects Symfony versions prior to 5.4.52, as well as 6.4.0 through 6.4.39, 7.0.0 through 7.4.11, and 8.0.0 through 8.0.11.

Impact

Exploitation of this vulnerability leads to a denial-of-service condition, causing the application to hang and become unresponsive for an extended period.

Reproduction

The vulnerability can be reproduced by using a YAML header that is excessively large, such as one that includes 100,000 '1' characters, or by adding a significant number of comments. This crafted input will cause the parser to hang indefinitely, demonstrating the catastrophic backtracking issue.

Remediation

Users can upgrade to Symfony versions 5.4.52, 6.4.40, 7.4.12, or 8.0.12 to address this vulnerability.

Added: Jul 15, 2026, 6:01 AM
Updated: Jul 15, 2026, 6:01 AM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
2.5
exploitability
8.4
remediation
0.0
relevance
9.2
threat
4.8
urgency
2.9
incentive
4.2

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.