Incomplete List of Disallowed Inputs Affecting symfony/html-sanitizer package, versions >=6.1, <6.4.50>=7.0.0, <7.4.23>=8.0.0, <8.1.11


Severity

Recommended
0.0
low
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.24% (17th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-PHP-SYMFONYHTMLSANITIZER-23188851
  • published1 Dec 2026
  • disclosed5 Nov 2026
  • creditShriyansh Gupta, Ilia Alshanetsky, 李智遥

Introduced: 5 Nov 2026

NewCVE-2026-121949  (opens in a new tab)
CWE-184  (opens in a new tab)

How to fix?

Upgrade symfony/html-sanitizer to version 6.4.50, 7.4.23, 8.1.11 or higher.

Overview

symfony/html-sanitizer is a Provides an object-oriented API to sanitize untrusted HTML input for safe insertion into a document's DOM.

Affected versions of this package are vulnerable to Incomplete List of Disallowed Inputs via UrlAttributeSanitizer::getSupportedAttributes(), which omits srcset and imagesrcset from its list of handled attributes, causing the DOM visitor to preserve those attribute values verbatim. An attacker who controls the sanitized HTML can supply srcset or imagesrcset values pointing to hosts or schemes blocked by allowMediaSchemes(), allowMediaHosts(), or forceHttpsUrls(), and the browser will fetch images from those disallowed origins. The same URL placed in src is correctly dropped, confirming this is a missing sanitizer for two browser-active URL attributes rather than a configuration error.

CVSS Base Scores

version 4.0
version 3.1