Skip to main content
EPSS 0.3%top 76%

CVE-2026-59727: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in withastro astro

0
Low
VulnerabilityCVE-2026-59727cvecve-2026-59727cwe-79cwe-83cwe-116
Published: 07/27/2026 (07/27/2026, 19:42:32 UTC)
Source: CVE Database V5
Vendor/Project: withastro
Product: astro

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.

CVSS v4.0

Score 2.1low

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
None
User Interaction
Active
Vuln. Confidentiality
None
Vuln. Integrity
None
Vuln. Availability
None
Subsq. Confidentiality
Low
Subsq. Integrity
Low
Subsq. Availability
None
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

Affected software

withastro

astro

Affected versions
>=3.10.0 <7.0.4

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 07/29/2026, 23:47:02 UTC

Technical Analysis

The vulnerability in Astro (versions 3.10.0 through 7.0.3) involves improper neutralization of input during web page generation (CWE-79). When the transition:persist, transition:scope, or transition:persist-props directives are applied to client-hydrated components, Astro copies the directive values onto the <astro-island> element without HTML-escaping. If a developer passes untrusted, attacker-controlled input into these directives, it can lead to reflected XSS by breaking out of the attribute context and injecting arbitrary HTML/JavaScript into server-rendered output. This requires a non-idiomatic developer pattern and is not exploitable if untrusted input is not routed into these directives. The vulnerability is resolved in Astro version 7.0.4.

Potential Impact

Successful exploitation allows an attacker to inject arbitrary HTML or JavaScript into the server-rendered output, leading to reflected cross-site scripting (XSS). This can result in execution of malicious scripts in the context of the victim's browser. However, exploitation requires that the developer explicitly passes untrusted input into the vulnerable directives, which is not typical. The CVSS 4.0 score is low (2.1), reflecting the limited attack vector and required conditions.

Mitigation Recommendations

This vulnerability is fixed in Astro version 7.0.4. Users should upgrade to version 7.0.4 or later to remediate the issue. Applications that do not pass untrusted input into the affected transition directives are not vulnerable. No other vendor advisory or patch information is available; therefore, patch status is confirmed by the fixed version 7.0.4. No additional mitigation steps are indicated.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
GitHub_M
Date Reserved
2026-07-06T15:34:16.917Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 6a67c6709c2644c7f8d3da78

Added to database: 07/27/2026, 20:58:24 UTC

Last enriched: 07/29/2026, 23:47:02 UTC

Last updated: 09/10/2026, 20:02:38 UTC

Views: 83

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses