# 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

Source: https://aplosec.si/cve/CVE-2026-126364/

[AploSec](https://aplosec.si/) / [Disclosures](https://aplosec.si/disclosures/) / CVE-2026-126364

Medium 6.3 · Reported · Fixed in 7.4.7 · CWE-22 · npm

# Astro: Image endpoint in @astrojs/node can read files from a case-variant sibling of the output directory on case-sensitive filesystems

CVE-2026-126364 · published 2026-11-12

In plain words: this type of bug lets someone read or write files outside the folder they should be limited to (path traversal). A fixed release is listed.

## Summary

CVE-2026-126364 affects astro (npm) >= 5.14.3, < 7.4.7: the @astrojs/node /_image endpoint compares paths without preserving case, so a case-variant sibling of the output directory passes the containment check (CWE-22). Fixed in 7.4.7. CVSS 4.0 base score 6.3 (Medium), assigned by GitHub_M. Published 2026-11-12 by GitHub_M. Credit: Zachariah Mithani.

Astro is a web framework for content-driven websites. From 5.14.3 until 7.4.7, Astro's /_image endpoint compared the requested local-image path with the build output directory without preserving case on case-sensitive filesystems. A sibling directory whose path differed from the output directory only by letter case could therefore pass the containment check, allowing an unauthenticated requester to read image files accepted by the image service from outside the output directory. Exploitation required on-demand rendering with the @astrojs/node adapter, a case-sensitive filesystem, and a preexisting case-variant sibling directory; ordinary traversal to unrelated paths was already rejected. This issue is fixed in Astro version 7.4.7.

## Evidence

Reported to the maintainer. The public advisory and references below describe the evidence and preconditions; reporting status alone does not establish independent reproduction.

## Remediation

Upgrade astro to 7.4.7 or later. Releases in the affected range (>= 5.14.3, < 7.4.7) are vulnerable. See the linked advisory for details on affected release lines.

## Timeline

- 2026-11-12 CVE published

- 2026-11-13 Public record last updated

## References

- [CVE recordhttps://www.cve.org/CVERecord?id=CVE-2026-126364](https://www.cve.org/CVERecord?id=CVE-2026-126364)

- [Fix commithttps://github.com/withastro/astro/commit/7da442bb286e0c29e1c9e1add6727b7cbf434f1a](https://github.com/withastro/astro/commit/7da442bb286e0c29e1c9e1add6727b7cbf434f1a)

- [Releasehttps://github.com/withastro/astro/releases/tag/astro@7.4.7](https://github.com/withastro/astro/releases/tag/astro@7.4.7)

- [NVD recordhttps://nvd.nist.gov/vuln/detail/CVE-2026-126364](https://nvd.nist.gov/vuln/detail/CVE-2026-126364)

**Severity:** Medium 6.3 CVSS 4.0, scored by GitHub_M in the [CVE record](https://www.cve.org/CVERecord?id=CVE-2026-126364)

**Package:** astro

**Ecosystem:** npm

**Affected:** >= 5.14.3, < 7.4.7

**Fixed:** 7.4.7

**Weakness:** CWE-22

**CNA:** GitHub_M

**Credit:** Zachariah Mithani finder
