# CVE-2026-59727: Astro: Cross-site scripting via unescaped transition:* directive values on hydrated islands

- Severity: Low 2.1 (CVSS:4.0, scored by GitHub_M) `CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.39%, higher than 35% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-07-20T23:21:02.000Z
- Modified: 2026-10-24T13:10:00.147Z
- Also known as: GHSA-7pw4-f3q4-r2p2
- Weaknesses: CWE-79, CWE-83, CWE-116
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Astro is a web framework for content-driven websites. In versions 3.10.0 through 7.0.3, when a transition:persist, transition:scope, or transition:persist-props directive is applied to a client-hydrated (client:*) component, Astro copied the directive value onto the rendered <astro-island> element without HTML-escaping it. If a developer reflects attacker-controlled input into one of these directives, an attacker can break out of the attribute and inject arbitrary HTML/JavaScript into the server-rendered output, resulting in reflected cross-site scripting (XSS). Exploitation requires the application developer to have written a non-idiomatic pattern — passing untrusted, request-derived input directly into a transition directive. Astro applications that do not route untrusted input into these directives are unaffected. This issue has been fixed in version 7.0.4.

(As written by CVE List.)

## Affected

- withastro astro: >= 3.10.0, < 7.0.4
- astro (npm): from 3.10.0 before 7.0.4

## Every score

- GitHub_M: CVSS:4.0 2.1 Low `CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N`
- GitHub: CVSS:4.0 Low `CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N`

## References

- <https://github.com/withastro/astro/security/advisories/GHSA-7pw4-f3q4-r2p2> (exploit, web)
- <https://github.com/withastro/astro/pull/17212> (web)
- <https://github.com/withastro/astro/commit/7ba0bb1dc7516e88caff9abd7767322af44b0294> (web)
- <https://github.com/withastro/astro/releases/tag/astro@7.0.4> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-59727> (advisory)
- <https://github.com/withastro/astro> (package)

## Sources

- CVE List: [CVE-2026-59727](https://www.cve.org/CVERecord?id=CVE-2026-59727), CVE Terms of Use, modified 2026-07-28
- GitHub Advisory Database: [GHSA-7pw4-f3q4-r2p2](https://github.com/advisories/GHSA-7pw4-f3q4-r2p2), CC-BY-4.0, modified 2026-08-12
- NVD: [CVE-2026-59727](https://nvd.nist.gov/vuln/detail/CVE-2026-59727), Public domain, modified 2026-10-24

---

Page: https://cve.day/CVE-2026-59727 · Whole record: https://cve.day/CVE-2026-59727.json · Rebuilt by cve.day 2026-11-25T22:59:30.232Z
