Vulnerability · Published Aug 12, 2026 · Assigned by GitHub_M
CVE-2026-73422Astro: Reflected XSS via unescaped View Transition animation properties
Medium 5.3
In plain English
A medium-severity cross-site scripting in astro from withastro. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.5% (higher than 46% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
Astro is a web framework for content-driven websites. From 2.9.0 until 7.1.0, Astro's server-side View Transition CSS generator interpolates animation properties into an inline style element without escaping them for CSS and HTML contexts. An attacker-controlled View Transition animation value such as duration can terminate the generated style element and inject arbitrary HTML or JavaScript. The affected code is packages/astro/src/runtime/server/transition.ts; renderTransition passes sheet.toString() into markHTMLString(), while addAnimationProperty serializes duration through toTimeValue() and also handles easing, direction, delay, fillMode, and name. Exploitation requires an on-demand or server-rendered route to pass attacker-controlled data into a View Transition animation definition and can execute arbitrary JavaScript in the affected application's origin, allowing access to sensitive page data and authenticated actions available to the victim. This issue is fixed in version 7.1.0.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| npm | astro | 7.1.0 | GHSA-4g3v-8h47-v7g6 |
Affected products (as reported)
Weakness: CWE-79 · Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
References
- https://github.com/withastro/astro/security/advisories/GHSA-4g3v-8h47-v7g6 x_refsource_CONFIRM
- https://github.com/withastro/astro/pull/17393 x_refsource_MISC
- https://github.com/withastro/astro/commit/092da560eea77ee63a3e2c583c80d8238544e42b x_refsource_MISC
- https://github.com/withastro/astro/releases/tag/astro@7.1.0 x_refsource_MISC