CVE-2026-126364: Astro: Image endpoint in @astrojs/node can read files from a case-variant sibling of the output directory on case-sensitive filesystems
Published 2026-11-13 · Updated 2026-11-13 · Also known as GHSA-r3h5-4585-7x3w
Summary
The image endpoint in @astrojs/node improperly validates paths case-insensitively on case-sensitive filesystems, allowing unauthorized file reads from sibling directories. Engineering teams using Astro with the Node adapter on Linux or other case-sensitive filesystems should upgrade immediately.
Who is affected
Unauthenticated attackers can read image files from outside the build output directory if the server runs on a case-sensitive filesystem and a case-variant sibling directory exists. Only files accepted by the image service can be read, such as processed raster images or unchanged SVGs, and the attacker cannot create the required sibling directory structure themselves.
Exploitability
Exploitation requires high attack complexity because it depends on specific server filesystem characteristics and an unusual directory layout. The attack can be executed over the network without authentication or user interaction, resulting in low confidentiality impact.
Remediation
- Upgrade astro to version 7.4.7 or later
- Ensure no directory next to the build output directory differs from it only by letter case as a workaround before upgrading
How to check your project
- Check project dependencies to see if astro versions 5.14.3 through 7.4.6 or @astrojs/node versions up to 11.1.11 are in use
- Inspect the build output configuration and filesystem layout for case-variant sibling directories on case-sensitive operating systems
Automated analysis of the published advisory data, generated 2026-11-18. Not human-reviewed; verify against the official advisory. How this works.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | Upgrade |
|---|---|---|---|---|
| npm | @astrojs/node |
>= 0, <= 11.1.11 | not published | - |
| npm | astro |
>= 5.14.3, < 7.4.7 | 7.4.7 | npm install [email protected] |
Tracked tools affected
Astro · Astro security advisories · Fixed in Astro 7.4.7 release notes
CVSS 4.0 vector
CVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N
| Attack vector | Network |
|---|---|
| Attack complexity | High |
| Attack requirements | Present |
| Privileges required | None |
| User interaction | None |
| Confidentiality (vulnerable system) | Low |
| Integrity (vulnerable system) | None |
| Availability (vulnerable system) | None |
| Confidentiality (subsequent systems) | None |
| Integrity (subsequent systems) | None |
| Availability (subsequent systems) | None |
Base score is not computed for CVSS 4.0 vectors; severity is taken from the advisory.
FAQ
What causes the vulnerability?
The path validation check for requested local images compared directories case-insensitively, which incorrectly accepted paths in case-variant sibling directories on case-sensitive filesystems like Linux.
Is upgrading @astrojs/node sufficient to fix the vulnerability?
No, the vulnerable image endpoint is provided by astro, so you must upgrade astro to version 7.4.7 or later.
Can an attacker use this flaw for standard path traversal outside the output directory?
No, plain path traversal attacks like requesting arbitrary files outside the output directory were already rejected and are unaffected.
Original advisory description
References
- WEB https://github.com/withastro/astro/security/advisories/GHSA-r3h5-4585-7x3w
- ADVISORY https://nvd.nist.gov/vuln/detail/CVE-2026-126364
- WEB https://github.com/withastro/astro/commit/7da442bb286e0c29e1c9e1add6727b7cbf434f1a
- PACKAGE https://github.com/withastro/astro
- WEB https://github.com/withastro/astro/releases/tag/[email protected]
Source records: GHSA-r3h5-4585-7x3w (OSV.dev) · EPSS by FIRST, 2026-11-21.