Go standard library os
Root escape via symlink plus trailing slash in os
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.
First public PoC
None yetno public PoC found
Public PoCs00 on GitHub
CVSS7.8high · scored by CISA ADP · CWE-61
CISA KEV
Not listednot known exploited
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
Go standard library os
- < 1.25.12
- >= 1.26.0-0, < 1.26.5
- >= 1.27.0-0, < 1.27.0-rc.2
Fixed in 1.25.12, 1.26.5, 1.27.0-rc.2
Mitigation
Upgrade os to 1.25.12 or 1.26.5 or 1.27.0-rc.2 or later.
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.No PoC repositories found yet.