Skip to main content
← All vulnerabilities
CVE-2026-41305GHSA-QX2V-QP2M-JG93

PostCSS has XSS via Unescaped </style> in its CSS Stringify Output

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 8.5.10
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: poc
  • Automatable: no
  • Technical impact: partial

Summary

PostCSS takes a CSS file and provides an API to analyze and modify its rules by transforming the rules into an Abstract Syntax Tree. Versions prior to 8.5.10 do not escape `</style>` sequences when stringifying CSS ASTs. When user-submitted CSS is parsed and re-stringified for embedding in HTML `<style>` tags, `</style>` in CSS values breaks out of the style context, enabling XSS. Version 8.5.10 fixes the issue.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: poc · Automatable: no · Technical impact: partial

  3. Record last updated

Affected versions

  • postcss postcss

    fixed in 8.5.10

  • postcssnpm

    fixed in 8.5.10

References 2

GitHub · postcss/postcss