GHSA-WM2W-4MGJ-VW33
Vulnerability from github – Published: 2026-12-01 21:30 – Updated: 2026-12-01 21:30Description
The MetaRefreshAttributeSanitizer introduced for CVE-2026-48761 sanitizes the refresh URL only when the content attribute matches:
/^(\s*\d+\s*[;,]\s*url\s*=\s*)(["\']?)(.+?)\2(\s*)$/i
The browser grammar, the WHATWG shared declarative refresh steps, is broader: 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 regex misses are returned unchanged, so the attacker URL skips UrlSanitizer entirely and both allowLinkSchemes and allowLinkHosts are defeated for the refresh navigation.
$c = (new HtmlSanitizerConfig())->allowStaticElements()->allowLinkHosts(['trusted.example']);
$s = new HtmlSanitizer($c);
$s->sanitizeFor('head', '<meta http-equiv="refresh" content="0;url=https://evil.example/">');
// <meta http-equiv="refresh" />, correct
$s->sanitizeFor('head', '<meta http-equiv="refresh" content="0 url=https://evil.example/">');
$s->sanitizeFor('head', '<meta http-equiv="refresh" content="0;https://evil.example/">');
$s->sanitizeFor('head', '<meta http-equiv="refresh" content="9 , https://evil.example/">');
// URL survives in all three, host allow-list defeated
The rendered = is entity-decoded back to = by the HTML parser before the refresh algorithm runs, so the browser sees a valid directive. Because the URL never reaches UrlSanitizer, a javascript: refresh URL is not filtered either.
Three further spellings were found while fixing and are covered by the same patch: 0,https://evil.example/, .5;url=https://evil.example/ with an empty integer part, and the specification's incomplete-url= quirk 0;uhttps://evil.example/.
This is reachable under any configuration that allows meta with http-equiv and content, including the documented allowStaticElements() preset.
Resolution
The sanitizer now parses the value following the WHATWG shared declarative refresh steps, and it fails safe: once a value looks like a refresh directive, any parse that does not end in a sanitized URL causes the attribute to be dropped rather than passed through.
Reviewers should note one unavoidable consequence. sanitizeAttribute() receives only the element name and the attribute value, never http-equiv, so every <meta content> value must be treated alike. A value such as <meta name="description" content="10 tips for cooking"> is now dropped, or rewritten as a relative URL when allowRelativeLinks() is enabled, because that same string on an http-equiv="refresh" element does make a browser navigate. The collateral is bounded to meta content values beginning with a digit or a full stop.
The patches for this issue are available here for branch 6.4 (and forward-ported to 7.4, 8.1 and 8.2).
Credits
Symfony would like to thank Ilia Alshanetsky for reporting the issue.
{
"affected": [
{
"package": {
"ecosystem": "Packagist",
"name": "symfony/html-sanitizer"
},
"ranges": [
{
"events": [
{
"introduced": "6.1.0"
},
{
"fixed": "6.4.50"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Packagist",
"name": "symfony/html-sanitizer"
},
"ranges": [
{
"events": [
{
"introduced": "7.0.0"
},
{
"fixed": "7.4.23"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Packagist",
"name": "symfony/html-sanitizer"
},
"ranges": [
{
"events": [
{
"introduced": "8.0.0"
},
{
"fixed": "8.1.11"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Packagist",
"name": "symfony/symfony"
},
"ranges": [
{
"events": [
{
"introduced": "6.1.0"
},
{
"fixed": "6.4.50"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Packagist",
"name": "symfony/symfony"
},
"ranges": [
{
"events": [
{
"introduced": "7.0.0"
},
{
"fixed": "7.4.23"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Packagist",
"name": "symfony/symfony"
},
"ranges": [
{
"events": [
{
"introduced": "8.0.0"
},
{
"fixed": "8.1.11"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-121373"
],
"database_specific": {
"cwe_ids": [
"CWE-186",
"CWE-601"
],
"github_reviewed": true,
"github_reviewed_at": "2026-12-01T21:30:04Z",
"nvd_published_at": "2026-11-04T13:17:27Z",
"severity": "MODERATE"
},
"details": "### Description\n\nThe `MetaRefreshAttributeSanitizer` introduced for CVE-2026-48761 sanitizes the refresh URL only when the `content` attribute matches:\n\n```php\n/^(\\s*\\d+\\s*[;,]\\s*url\\s*=\\s*)([\"\\\u0027]?)(.+?)\\2(\\s*)$/i\n```\n\nThe browser grammar, the WHATWG shared declarative refresh steps, is broader: 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 regex misses are **returned unchanged**, so the attacker URL skips `UrlSanitizer` entirely and both `allowLinkSchemes` and `allowLinkHosts` are defeated for the refresh navigation.\n\n```php\n$c = (new HtmlSanitizerConfig())-\u003eallowStaticElements()-\u003eallowLinkHosts([\u0027trusted.example\u0027]);\n$s = new HtmlSanitizer($c);\n\n$s-\u003esanitizeFor(\u0027head\u0027, \u0027\u003cmeta http-equiv=\"refresh\" content=\"0;url=https://evil.example/\"\u003e\u0027);\n// \u003cmeta http-equiv=\"refresh\" /\u003e, correct\n\n$s-\u003esanitizeFor(\u0027head\u0027, \u0027\u003cmeta http-equiv=\"refresh\" content=\"0 url=https://evil.example/\"\u003e\u0027);\n$s-\u003esanitizeFor(\u0027head\u0027, \u0027\u003cmeta http-equiv=\"refresh\" content=\"0;https://evil.example/\"\u003e\u0027);\n$s-\u003esanitizeFor(\u0027head\u0027, \u0027\u003cmeta http-equiv=\"refresh\" content=\"9 , https://evil.example/\"\u003e\u0027);\n// URL survives in all three, host allow-list defeated\n```\n\nThe rendered `\u0026#61;` is entity-decoded back to `=` by the HTML parser before the refresh algorithm runs, so the browser sees a valid directive. Because the URL never reaches `UrlSanitizer`, a `javascript:` refresh URL is not filtered either.\n\nThree further spellings were found while fixing and are covered by the same patch: `0,https://evil.example/`, `.5;url=https://evil.example/` with an empty integer part, and the specification\u0027s incomplete-`url=` quirk `0;uhttps://evil.example/`.\n\nThis is reachable under any configuration that allows `meta` with `http-equiv` and `content`, including the documented `allowStaticElements()` preset.\n\n### Resolution\n\nThe sanitizer now parses the value following the WHATWG shared declarative refresh steps, and it fails safe: once a value looks like a refresh directive, any parse that does not end in a sanitized URL causes the attribute to be dropped rather than passed through.\n\nReviewers should note one unavoidable consequence. `sanitizeAttribute()` receives only the element name and the attribute value, never `http-equiv`, so every `\u003cmeta content\u003e` value must be treated alike. A value such as `\u003cmeta name=\"description\" content=\"10 tips for cooking\"\u003e` is now dropped, or rewritten as a relative URL when `allowRelativeLinks()` is enabled, because that same string on an `http-equiv=\"refresh\"` element does make a browser navigate. The collateral is bounded to meta `content` values beginning with a digit or a full stop.\n\nThe patches for this issue are available [here](https://github.com/symfony/symfony/commit/2d4c4fe36200858b91132a95076fff3d9de89d26) for branch 6.4 (and forward-ported to 7.4, 8.1 and 8.2).\n\n### Credits\n\nSymfony would like to thank [Ilia Alshanetsky](https://github.com/iliaal) for reporting the issue.",
"id": "GHSA-wm2w-4mgj-vw33",
"modified": "2026-12-01T21:30:05Z",
"published": "2026-12-01T21:30:04Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/symfony/symfony/security/advisories/GHSA-wm2w-4mgj-vw33"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-121373"
},
{
"type": "WEB",
"url": "https://github.com/symfony/symfony/commit/2d4c4fe36200858b91132a95076fff3d9de89d26"
},
{
"type": "WEB",
"url": "https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/html-sanitizer/CVE-2026-121373.yaml"
},
{
"type": "WEB",
"url": "https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/symfony/CVE-2026-121373.yaml"
},
{
"type": "PACKAGE",
"url": "https://github.com/symfony/symfony"
},
{
"type": "WEB",
"url": "https://github.com/symfony/symfony/releases/tag/v6.4.50"
},
{
"type": "WEB",
"url": "https://github.com/symfony/symfony/releases/tag/v7.4.23"
},
{
"type": "WEB",
"url": "https://github.com/symfony/symfony/releases/tag/v8.1.11"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N",
"type": "CVSS_V4"
}
],
"summary": "Symfony: HtmlSanitizer MetaRefreshAttributeSanitizer Matches Only a Narrow Subset of the Browser Refresh Grammar: Incomplete Fix for CVE-2026-48761"
}
Drag nodes to arrange them. Double-click a related vulnerability to open it, or a source to visit its link. The Physics button on the left tunes the layout and the simulation; the legend at the bottom left hides or shows nodes by kind and by sighting type.
Sightings
| Author | Source | Type | Date | Other |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or observed by the user.
- Confirmed: The vulnerability has been validated from an analyst's perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
- Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
- Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
- Not confirmed: The user expressed doubt about the validity of the vulnerability.
- Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Vulnerability timeline
Sightings and recorded dates, grouped by day · UTC
How durations are calculated
Following the VTEM framework (Black Hat USA 2015), time to patch starts when the vendor or a coordinator was informed, total time to patch at discovery, and disclosure to patch at public disclosure; vendor response time runs from the report to its acknowledgement. Time to exploit and time unpatched start at the earliest discovery or report, falling back to public disclosure. Unpatched time ends at the first recorded patch, or the calculation time when no patch is recorded. Exploitation to patch shows the interval between those two events; a published proof of concept is a public exploit, not exploitation. The method is described in a publication.
Each result shows its source dates. A negative interval means the end event came first; when date-only inputs leave the order open, the result says so. Date-only inputs are approximate. The earliest evidence wins: KEV report dates and sightings are labelled as such. Records describing another vulnerability are listed but never calculated from, and a PoC alone does not establish exploitation. Missing patch evidence does not prove that no patch exists. Filters below change the event list only.
Loading timeline…
The approach is described in our paper Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion.
Browse all ATT&CK techniques and the vulnerabilities related to each.
Related by attack behaviour
Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.