7.8high
Root escape via symlink plus trailing slash in os
- Severity
- 7.8high CVSS:3.1 by CISA-ADP
- Exploit likelihood
- 0.22% (higher than 13% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- Go
- Also known as
- GO-2026-4970BIT-GOLANG-2026-39822
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.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| os | before 1.25.12, from 1.26.0-0 before 1.26.5, from 1.27.0-0 before 1.27.0-rc.2 | CVE List |
| stdlib (Go) | before 1.25.12, from 1.26.0-0 before 1.26.5, from 1.27.0-0 before 1.27.0-rc.2 | Go Vulnerability Database |
| golang go | from 1.24.0 before 1.25.12, from 1.26.0 before 1.26.5, 1.27 | NVD |
| golang (Bitnami) | before 1.25.12, from 1.26.0-0 before 1.26.5, from 1.27.0-0 before 1.27.0 | Bitnami Vulnerability Database |
All scores
| CISA-ADP | 7.8high CVSS:3.1 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| Bitnami Vulnerability Database | high rating |
Classification
SSVC (CISA-ADP): exploitation none, automatable no, technical impact total.
What each source says
CVE List
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.
NVD (es)
En sistemas Unix, abrir un archivo en un os.Root sigue incorrectamente los enlaces simbólicos a ubicaciones fuera del Root cuando el componente final de una ruta es un enlace simbólico y la ruta termina en /. Por ejemplo, ’root.Open(“symlink/”)’ abrirá “symlink” incluso cuando “symlink” es un enlace simbólico que apunta fuera de la raíz.
References
| https://go.dev/issue/79005 | fix, issue-tracking, patch, report | |
| https://groups.google.com/g/golang-announce/c/OrmQE_Yp5Sc | advisory, mailing-list, patch, vendor-advisory, web | |
| https://go.dev/cl/797880 | fix, patch | |
| https://pkg.go.dev/vuln/GO-2026-4970 | advisory, vendor-advisory | |
| https://nvd.nist.gov/vuln/detail/CVE-2026-39822 | web | |
Related
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-39822 changed 2026-07-08 | CVE Terms of Use |
| Go Vulnerability Database | GO-2026-4970 changed 2026-11-23 | CC-BY-4.0 |
| NVD | CVE-2026-39822 changed 2026-10-25 | Public domain |
| Bitnami Vulnerability Database | BIT-GOLANG-2026-39822 changed 2026-09-08 | Apache-2.0 |