XSS in Astro

CVE-2026-54298

Astro is a web framework. Prior to 6.4.6, the spreadAttributes function in Astro's server-side rendering pipeline iterates over object keys and passes them directly to addAttribute, which interpolates the key into the HTML output without escaping. When a developer uses the spread syntax {...props} on an HTML element and the object keys come from an untrusted source (API, CMS, URL parameters), an attacker can inject arbitrary HTML attributes including event handlers like onmousemove, onclick, or break out of the attribute context entirely to inject new elements. This vulnerability is fixed in 6.4.6.

Vulnerability class: XSS (Cross-Site Scripting)

Published · last modified .

CVSS v3 metric

CVSS v3 base score 4.2 (Medium). Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:N.

EPSS exploit prediction

EPSS: 0.002 (12.2th percentile), scored .

Very low probability of exploitation in the next 30 days; routine patching cadence is appropriate. 12th percentile — 12.2% of CVEs in the catalogue have a lower EPSS than this one. How to read EPSS.

EPSS trend (30 days)EPSS over the last 30 days for CVE-2026-54298: held from 0.002 to 0.002.

EPSS over last 30 days · oldest: 0.002 · newest: 0.002 · change: 0.000

Affected products

Weakness classification (CWE)

References

Frequently asked questions

What is CVE-2026-54298?
CVE-2026-54298 is a medium-severity vulnerability in Astro, classified under Cross-site Scripting. CVSS score: 4.2/10. Published 2026-06-22.
How severe is CVE-2026-54298?
Medium severity. CVSS v3 base score is 4.2 out of 10.