Skip to main content
← All vulnerabilities
CVE-2026-39822GO-2026-4970BIT-GOLANG-2026-39822

Root escape via symlink plus trailing slash in os

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 1.25.12, 1.26.5, 1.27.0-rc.2
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: none
  • Automatable: no
  • Technical impact: total

Summary

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.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: none · Automatable: no · Technical impact: total

  3. Record last updated

Affected versions

  • os

    fixed in 1.25.12; From 1.26.0-0 · fixed in 1.26.5; From 1.27.0-0 · fixed in 1.27.0-rc.2

  • stdlibGo

    fixed in 1.25.12; From 1.26.0-0 · fixed in 1.26.5; From 1.27.0-0 · fixed in 1.27.0-rc.2

References 4

go.dev

groups.google.com

pkg.go.dev