symfony/html-sanitizer vulnerabilities

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

Registry
Composer
Latest
8.1.11
License
MIT

5 known advisories

The latest version, 8.1.11, is not affected by any of them. Projects on older versions may be.

Update to the latest version:composer require symfony/html-sanitizer:^8.1.11

Is your project on an affected symfony/html-sanitizer?

Private repo? Upload its lockfile instead, or connect GitHub to check every repo.

Look after several Laravel or PHP apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie

Security advisories for symfony/html-sanitizer

  • MediumCVE-2026-48760GHSA-v3wm-qf9p-c54915 Jun 2026

    Symfony: HtmlSanitizer URL Parser Deny Gates Underinclusive: Percent-Encoded BiDi Marks and Unicode Whitespace Bypass Visual-Spoofing Defense

    Affected
    >=6.1.0 <6.4.41 · >=7.0.0 <7.4.13 · >=8.0.0 <8.0.13
    Fixed in
    6.4.41, 7.4.13, 8.0.13
  • MediumCVE-2026-48761GHSA-x5qj-865h-mgvm15 Jun 2026

    Symfony: HtmlSanitizer UrlAttributeSanitizer Misses URL Attributes

    Affected
    >=6.1.0 <6.4.41 · >=7.0.0 <7.4.13 · >=8.0.0 <8.0.13
    Fixed in
    6.4.41, 7.4.13, 8.0.13
  • LowCVE-2026-45753GHSA-hhg7-c65m-h7ff28 May 2026

    Symfony's HtmlSanitizer UrlAttributeSanitizer Omits action/formaction/poster/cite — `javascript`: URI Survives Sanitization (XSS)

    Affected
    >=6.1.0 <6.4.40 · >=7.0.0 <7.4.12 · >=8.0.0 <8.0.12
    Fixed in
    6.4.40, 7.4.12, 8.0.12
  • MediumCVE-2026-45066GHSA-qc95-4862-92fh27 May 2026

    Symfony has an HtmlSanitizer allowLinkHosts() / allowMediaHosts() Bypass via URL-Parser Differentials and <area> Misclassification

    Affected
    >=6.1.0 <6.4.40 · >=7.0.0 <7.4.12 · >=8.0.0 <8.0.12
    Fixed in
    6.4.40, 7.4.12, 8.0.12
  • MediumCVE-2026-45064GHSA-h5vq-qfcg-4m6p27 May 2026

    Symfony's HtmlSanitizer URL Attributes Pass Through BiDi Override Characters → Visual href Spoofing

    Affected
    >=6.1.0 <6.4.40 · >=7.0.0 <7.4.12 · >=8.0.0 <8.0.12
    Fixed in
    6.4.40, 7.4.12, 8.0.12

Is your symfony/html-sanitizer version vulnerable?

Which of your client projects still run an old symfony/html-sanitizer?

NPMscan reads the composer.lock in every GitHub repo you pick and checks each installed version against these advisories, including the packages your packages pull in. Each finding comes with the command that fixes it.

Other Composer packages

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily. Package details from the Composer registry.