CVE-2026-121373: Symfony: HtmlSanitizer MetaRefreshAttributeSanitizer Matches Only a Narrow Subset of the Browser Refresh Grammar (Incomplete Fix for CVE-2026-48761)
The Symfony HtmlSanitizer component MetaRefreshAttributeSanitizer, introduced to fix CVE-2026-48761, sanitizes the refresh URL of content attributes of meta tags using a regular expression that is too narrow, allowing sanitization to be bypassed, and resulting in potential URL redirection to untrusted sites in Symfony versions 6.1.x prior to 6.4.50, 7.x prior to 7.4.23, and 8.x prior to 8.1.11.
The shared declarative refresh steps in the WHATWG HTML Standard require a broader approach: the separator after the time may be ASCII whitespace alone, with no ; or ,, and the url= keyword is optional. Directives the browser honours, but the regular expression misses are returned unchanged, so the attacker URL skips UrlSanitizer entirely and both allowLinkSchemes and allowLinkHosts are defeated for the refresh navigation.
This is reachable under any configuration that allows meta with http-equiv and content, including the documented allowStaticElements() preset.
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
Symfony HtmlSanitizerto a version that resolves this vulnerability.Fixed in 6.4.50 - Upgrade
Upgrade
Symfony HtmlSanitizerto a version that resolves this vulnerability.Fixed in 7.4.23 - Upgrade
Upgrade
Symfony HtmlSanitizerto a version that resolves this vulnerability.Fixed in 8.1.11
Event History
Frequently Asked Questions
Which configurations are affected?
Any HtmlSanitizer configuration that permits meta elements with http-equiv and content attributes is affected. This includes the documented allowStaticElements() preset.
What does an attacker need to exploit this issue?
An attacker needs to supply sanitized HTML containing a meta refresh directive that uses browser-valid refresh syntax not matched by the sanitizer's narrow regular expression. User interaction is required because the impact is navigation to an untrusted site.
Do allowed link schemes and hosts mitigate the issue?
No. For the missed refresh formats, the attacker-controlled URL bypasses UrlSanitizer entirely, so allowLinkSchemes and allowLinkHosts are not applied.
What can be done before updating?
Prevent untrusted HTML from containing meta elements with http-equiv and content attributes, or disable configurations and presets that allow them. This removes the reachable meta refresh path described for this issue.
Which Symfony releases contain the fix?
The issue is fixed in Symfony 6.4.50, 7.4.23, and 8.1.11. Affected releases are 6.1.x before 6.4.50, 7.x before 7.4.23, and 8.x before 8.1.11.