CVE-2026-27139 FileInfo can escape from a Root in os
Attackers can read file metadata outside the intended root directory on Unix systems using Go's os package directory listing functions.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2026-27139?
CVE-2026-27139 is a low-severity path traversal vulnerability in Golang Go, published on 6 Mar 2026. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
On Unix platforms, when listing the contents of a directory using File.ReadDir or File.Readdir the returned FileInfo could reference a file outside of the Root in which the File was opened. The impact of this escape is limited to reading metadata provided by lstat from arbitrary locations on the filesystem without permitting reading or writing files outside the root.
Weakness: CWE-22
Which versions are affected by CVE-2026-27139?
2 open source packages ship an affected version, including golang and stdlib. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
golang Bitnami | All versions | 1.25.8, 1.26.1 |
stdlib Go | All versions | 1.25.8, 1.26.1 |
Products include Golang Go.
How do I fix CVE-2026-27139?
Upgrade golang to a fixed version for your release line: 1.25.8 or 1.26.1.
Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.
Is CVE-2026-27139 being exploited?
There is no known exploitation of CVE-2026-27139 in the wild and no public exploit code.
Other vulnerabilities in Golang Go
- CVE-2020-0601 Microsoft Windows CryptoAPI Spoofing
- CVE-2026-27143 Missing bound checks can lead to memory corruption in safe Go in cmd/compile
- CVE-2024-24790 Unexpected behavior from Is methods for IPv4-mapped IPv6 addresses in net/netip
- CVE-2023-39320 Arbitrary code execution via go.mod toolchain directive in cmd/go
- CVE-2023-24540 Improper handling of JavaScript whitespace in html/template
Sources
Also known as AZL-79532, AZL-79535, AZL-79541, BELL-CVE-2026-27139, BIT-golang-2026-27139, CLEANSTART-2026-LB27311 and 533 more.