CVE-2026-39822: On Unix systems, opening a file in an os.Root improperly follows symlinks to locations outside of the Root when the final path component of the a path is a symbolic link and the path ends in /.
High CVSS 7.8
- CVE id
- CVE-2026-39822
- Published
- Last modified
Affected packages
| Package | Affected versions | Fixed in |
|---|---|---|
| Go Runtimes and servers |
>= 1.24.0, < 1.25.12 >= 1.26.0, < 1.26.5 |
1.25.12, 1.26.5 |
How to fix it
Upgrade Go to the fixed release of the line you run: 1.25.12, 1.26.5.
go version
- Build with the patched Go release (set "toolchain" in go.mod, or the golang image tag) and redeploy: Go programs include the standard library, so they must be rebuilt.
A free AIssue account reads the runtime versions your repositories pin (version files, Dockerfiles, build files) and tells you when one is affected.
Details
On Unix systems, opening a file in an os.Root improperly follows symlinks to locations outside of the Root when the final path component of the a path is a symbolic link and the path ends in /. For example, 'root.Open("symlink/")' will open "symlink" even when "symlink" is a symbolic link pointing outside of the root.
References
Am I affected?
Upload or paste your lockfile. We check every package version in it against OSV.dev, this advisory included, and email you the vulnerable ones with the version that fixes them. Free, and no account needed.
About this data
Source: National Vulnerability Database (NVD) (public domain). Severity comes from the advisory's own rating when it has one, else from its CVSS score.