Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessIdentify Astro SSR deployment with non-root base path
-
DeliveryCraft HTTP request path sharing base as non-boundary prefix (e.g., /appX/admin with base /app)
-
ExploitRouter's startsWith check matches, strips prefix, resolves request to protected /admin route
-
ExecutionMiddleware evaluates unstripped /appX/admin pathname
-
PersistAuthorization rule finds no match
-
ImpactUnauthenticated access to protected route granted
Vulnerability Assessment
| Weakness |
CWE
|
| Exploitation Conditions | Three specific conditions must all be present simultaneously for exploitation: (1) Astro must be deployed in SSR mode with a live server runtime - fully static site exports do not execute middleware and are completely unaffected; (2) a non-root base path must be explicitly configured in astro.config.mjs (e.g., base: '/app' or base: '/docs'); and (3) the application's Astro middleware must authorize requests by comparing context.url.pathname directly against base-prefixed route patterns. Applications that enforce authorization via session tokens, HTTP headers, external auth proxies, or resolved internal route objects rather than raw pathname string matching are not affected. The bypass grants access only to routes the flawed middleware was intended to block and does not provide elevated OS or framework-level privileges beyond what those routes expose. |
| Impact | The CVSS 4.0 vector (AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N, score 6.3) appropriately captures the key tension: the bypass is trivially simple to execute once the right deployment conditions are in place, but those conditions - a non-root base path combined with middleware-based pathname authorization in SSR mode - are not universal across Astro deployments. The AT:P (Attack Requirements: Present) qualifier in the 4.0 vector correctly signals these non-default prerequisites. EPSS data is absent from the provided input, and the vulnerability has no CISA KEV listing, indicating no confirmed mass exploitation. Impact is bounded by whatever the bypassed middleware was protecting; the framework does not inherently enable privilege escalation beyond route access. Even a mid-sized municipal IT team in mielec deploying an Astro-based intranet portal with server-side access controls should treat this as high priority if the deployment uses a non-root base path, as the bypass requires nothing more than a crafted HTTP path and the fix is a single version bump. Fully static Astro sites that export to HTML and deploy without a server runtime are entirely unaffected, since middleware never executes in that model. Overall, real-world severity is moderate but sharply context-dependent. |
| Exploit ScenarioDerived | An attacker identifies an Astro SSR deployment with base '/app' and middleware protecting the '/app/admin' management panel. They send an unauthenticated HTTP GET request to '/appX/admin'; the router's startsWith prefix check matches '/app', slices the path to '/admin', and routes the request to the admin panel, while the middleware evaluates '/appX/admin' and finds no match against its '/app/admin' protection rule, granting access without authentication. No public exploit code has been identified at time of analysis, but the bypass requires only a crafted HTTP path and no tooling beyond a standard HTTP client. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Sep 02, 2026
Base-path prefix bypass in Astro prior to 7.2.4 allows unauthenticated remote attackers to reach protected server-side routes by exploiting a missing path-segment boundary check in the framework's base-stripping logic. When a non-root base (e.g., '/app') is configured, a request to '/appX/admin' passes the router's prefix check and resolves to the internal '/admin' route while middleware still observes '/appX/admin' in context.url.pathname, causing pathname-based authorization rules to silently fail. Version 7.2.4 patches the flaw across all four affected subsystems; no public exploit code has been identified at time of analysis, and the vulnerability is not listed in the CISA KEV catalog.
RemediationAI
Upgrade Astro to version 7.2.4 or later; the patched release is available at https://github.com/withastro/astro/releases/tag/astro@7.2.4. The fix replaces all four independent implementations of the base-stripping logic with a unified, boundary-aware stripRequestBase utility from @astrojs/internal-helpers/path (PR: https://github.com/withastro/astro/pull/17701, commit: https://github.com/withastro/astro/commit/05763a0884aabb1da78a2749d5bb9d41ae620527). If an immediate upgrade is not feasible, rewrite middleware authorization to check a route object, session data, or normalized canonical route identifier rather than raw context.url.pathname, which removes the dependency on the flawed base-stripping behavior entirely. As a short-term structural workaround, changing the base configuration to the root path (base: '/') eliminates the condition required for the bypass, though this alters all public URLs and requires redirect management to avoid breaking existing links.
Affected VersionsENISA
Affected Packages
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
The vulnerability exists in the Astro web framework (cpe:2.3:a:withastro:astro:*:*:*:*:*:*:*:*), specifically in its base-path stripping logic used for SSR deployments with a non-root base configuration. CWE-187 (Improper Handling of Partial/Incomplete Values) applies: the original code called String.prototype.startsWith() against the configured base string and then sliced the path without confirming that the match ended at a segment boundary - that is, that the character immediately following the base prefix was '/' or end-of-string. This flaw was independently replicated across four modules: BaseApp.removeBase, FetchState.stripBase, match-request.ts's removeBase, and computePathnameFromDomain in the i18n domain routing module. Because the router and middleware both called the same flawed stripping function, they agreed on the broken result in normal cases, but a crafted path that shared the base as a non-boundary prefix caused the router to resolve to the protected route while the middleware's authorization check evaluated the original, un-stripped path and found no match. The fix introduces a shared stripRequestBase helper in @astrojs/internal-helpers/path that enforces the segment-boundary requirement before any stripping occurs.
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
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N
Network-exploitable but requires both a non-root base config and pathname-based middleware auth (AC:H); no privileges needed (PR:N); impact limited to bounded route access with no availability or scope change.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
1DescriptionCVE.org
Astro is a web framework for content-driven websites. Prior to 7.2.4, Astro stripped a configured non-root base path from request pathnames using a string-prefix check without verifying a path-segment boundary. With base "/app", a request to "/appX/admin" resolved internally to the protected "/admin" route while middleware observed "/appX/admin" in context.url.pathname. In applications that authorize base-prefixed routes by inspecting context.url.pathname, an unauthenticated remote attacker could bypass pathname-based middleware authorization and reach protected routes. This issue is fixed in version 7.2.4.
Blast Radius
ecosystem impact- 1 npm packages depend on astro (1 direct, 0 indirect)
Ecosystem-wide dependent count for version 7.2.4.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.
SQL Injection exists in the Saxum Astro 4.0.14 component for Joomla!. Rated critical severity (CVSS 9.8), this vulnerabi
Astro web framework versions prior to 9.5.4 contain a server-side request forgery vulnerability in error page handling t
Authorization bypass in the Astro web framework version 6.4.7 lets remote unauthenticated attackers reach protected rout
Astro is a web framework for content-driven websites. Rated high severity (CVSS 7.8), this vulnerability is remotely exp
Server-side request forgery in Astro's built-in image proxy lets unauthenticated remote attackers force the server to fe
Astro is a web framework for content-driven websites. Rated high severity (CVSS 7.2), this vulnerability is remotely exp
Astro is a web framework for content-driven websites. Rated medium severity (CVSS 6.9), this vulnerability is remotely e
Astro is a web framework. Rated medium severity (CVSS 6.9), this vulnerability is remotely exploitable, no authenticatio
Astro is a web framework. Rated medium severity (CVSS 6.5), this vulnerability is remotely exploitable, no authenticatio
Unvalidated reflection of the X-Forwarded-Host header in Astro (versions before 5.14.3) lets remote, unauthenticated att
Astro web framework versions 9.0.0 through 9.5.3 fail to validate remote image domains when the inferSize option is enab
Astro is a web framework. Rated medium severity (CVSS 5.4), this vulnerability is remotely exploitable, no authenticatio
EUVD-2026-70213
GHSA-376h-93r7-7g6f
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB