Root escape via symlink plus trailing slash in os
Summary
| CVE | CVE-2026-39822 |
|---|---|
| State | PUBLISHED |
| Assigner | Go |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2026-07-08 17:17:21 UTC |
| Updated | 2026-07-13 14:54:26 UTC |
| Description | 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. |
Risk And Classification
Primary CVSS: v3.1 7.8 HIGH from ADP
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
EPSS: 0.001810000 probability, percentile 0.078110000 (date 2026-07-12)
Problem Types: CWE-61 | CWE-61: UNIX Symbolic Link (Symlink) Following | CWE-61 CWE-61 UNIX Symbolic Link (Symlink) Following
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 3.1 | ADP | DECLARED | 7.8 | HIGH | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| 3.1 | 134c704f-9b21-4f2e-91b3-4a467353bcc0 | Secondary | 7.8 | HIGH | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
CVSS v3.1 Breakdown
Attack Vector
LocalAttack Complexity
LowPrivileges Required
LowUser Interaction
NoneScope
UnchangedConfidentiality
HighIntegrity
HighAvailability
HighCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
NVD Known Affected Configurations (CPE 2.3)
Vendor Declared Affected Products
| Source | Vendor | Product | Version | Platforms |
|---|---|---|---|---|
| CNA | Go Standard Library | Os | affected 1.25.12 semver | Not specified |
| CNA | Go Standard Library | Os | affected 1.26.0-0 1.26.5 semver | Not specified |
| CNA | Go Standard Library | Os | affected 1.27.0-0 1.27.0-rc.2 semver | Not specified |
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| go.dev/cl/797880 | [email protected] | go.dev | Patch |
| pkg.go.dev/vuln/GO-2026-4970 | [email protected] | pkg.go.dev | Vendor Advisory |
| go.dev/issue/79005 | [email protected] | go.dev | Issue Tracking, Patch |
| groups.google.com/g/golang-announce/c/OrmQE_Yp5Sc | [email protected] | groups.google.com | Mailing List, Patch, Vendor Advisory |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
Vendor Comments And Credit
Discovery Credit
CNA: Mundur (https://github.com/M0nd0R) (en)
There are currently no legacy QID mappings associated with this CVE.