Cross-site scripting in Astro through dynamic tag names
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- Passive
- Attack complexity
- Low
- Attack requirements
- Present
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- Low · Low · None
- Fix status
- Fixed
Attack profile from CVSS 4.0 · CNA. Fix status from CNA and GitHub. Impact type from CWE-79.
Summary
Astro versions before 7.4.5 render a string used as a dynamic element name as raw HTML after applying an incomplete character filter. A remote attacker who can supply untrusted input used as all or part of an element name can inject event-handler markup into a page (CWE-79, CWE-184). The .astro dynamic-tag renderer, JSX renderer, and MDX renderer are affected, and exploitation requires the application to use request-controlled or stored untrusted data as an element name. The CVSS 4.0 vector indicates a low-severity flaw that needs user interaction.
Written with Claude Haiku 5.5 from the sources below · 2026-11-13
Description from the CNA
Astro is a web framework for content-driven websites. Prior to 7.4.5, Astro rendered a string used as a dynamic element name as raw HTML after applying an incomplete character filter. A / in the string could make an HTML parser treat the remainder as attributes, allowing untrusted element-name input to inject event-handler markup. The .astro dynamic-tag renderer, JSX renderer, and MDX renderer were affected, and exploitation required an application to use request-controlled or stored untrusted data as all or part of an element name. This issue is fixed in version 7.4.5.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| withastro | astro | before 7.4.5 | 7.4.5 | Patch available | CNA |
| — | astro (npm) | before 7.4.5 | 7.4.5 | Patch available | GHSA-mh32-jxcr-mh9f |
- astro Vendorwithastro Affected before 7.4.5 Fixed in 7.4.5 Patch available CNA
- astro (npm) Vendor— Affected before 7.4.5 Fixed in 7.4.5 Patch available GHSA-mh32-jxcr-mh9f
Remediation
Update Astro to version 7.4.5, which fixes this issue. The sources list no fixed version for any other release line.
Written with Claude Haiku 5.5 from the sources below · 2026-11-13
- Fix · CNA astro (withastro) Fixed in 7.4.5
- Fix · GHSA-mh32-jxcr-mh9f astro (npm) Fixed in 7.4.5 Advisory →
Timeline
- 2026-11-12 Threatist record created from CVE-2026-126361
- 2026-11-13 Alias added: GHSA-mh32-jxcr-mh9f
- 2026-11-13 Fix available: npm/[email protected] · GHSA-mh32-jxcr-mh9f
- 2026-11-13 CVSS score added · GHSA-mh32-jxcr-mh9f
- 2026-11-13 Weakness changed · GHSA-mh32-jxcr-mh9f
- 2026-11-13 6 new references · GHSA-mh32-jxcr-mh9f
References
Other 5
- https://github.com/withastro/astro/security/advisories/GHSA-mh32-jxcr-mh9f
- https://github.com/withastro/astro/pull/18520
- https://github.com/withastro/astro/commit/e023abac912d7cb6af2b9fb5107ef5dabc667096
- https://github.com/withastro/astro/releases/tag/[email protected]
- https://github.com/withastro/astro
More withastro vulnerabilities
- TI-2026-26147 Astro: Unauthenticated Path Override via `x-astro-path` / `x_astro_path` CVSS 3.1CRITICAL 9.1
- TI-2026-42600 Astro 6.4.7 Authorization Bypass via Decode Iteration Limit and Rewrite Path Canonicalization Mismatch CVSS 3.1HIGH 8.2
- TI-2024-37142 Server source code is exposed to the public if sourcemaps are enabled CVSS 4.0HIGH 7.8
- TI-2025-35987 Astro Cloudflare adapter is vulnerable to Server-Side Request Forgery via /_image endpoint CVSS 3.1HIGH 7.2
- TI-2025-34958 Unauthorized third-party images in Astro’s _image endpoint CVSS 4.0MEDIUM 6.9
- TI-2026-51542 Astro: Unauthenticated path override in the @astrojs/vercel ISR function CVSS 3.1MEDIUM 6.5
Sources
- CVE-2026-126361 · CVE Program
- CVE-2026-126361 · NVD
- FIRST EPSS
- GHSA-mh32-jxcr-mh9f · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences