An attacker can keep a PHP worker busy for seconds or minutes with one small YAML document. Several parts of the YAML parser took time that grew much faster than the size of the document. Send enough of these and your app stops answering, which is a denial of service.
Who is affected
Any code that parses untrusted YAML with symfony/yaml (also part of symfony/symfony), with the default flags.
The Symfony advisory says that on 7.4 and later this includes #[MapRequestPayload] endpoints when the Yaml component is installed and the endpoint doesn't restrict acceptFormat. There, one unauthenticated request with a YAML content type is enough, even with a JSON body. On 6.4, #[MapRequestPayload] only accepts YAML when the app registers a yaml request format.
Apps that only parse their own YAML files, such as config, aren't exposed.
What to do
Update to 5.4.56, 6.4.50, 7.4.23 or 8.1.11. If you're on 8.0, update to 8.1.11. The fix makes parse time grow in step with the document. On 7.4 and later, #[MapRequestPayload] also stops decoding YAML and CSV payloads unless acceptFormat lists them.
Reported by Sebastian Bergmann.