Building a malicious package that uses "//go:cgo_import_dynamic" or links against a crafted PE object on Windows could pass unsafe library arguments to the external linker.
- CVSS
- 8.8High
- Chance of exploitation (EPSS)
- 0.58%
- Published
- Nov 11, 2026
- In the news
- Not yet
What to do
A serious security flaw in Go Toolchain Cmd Cgo, Go Toolchain Cmd Compile, Go Toolchain Cmd Link that can be attacked over the network without logging in, if someone is tricked into an action. No attacks are reported yet; it can go in your normal patch cycle.
Action: Check the vendor's advisory in the references and apply updates as soon as they are available.
Fixed in: 1.26.11, 1.27.4
Affected versions
- Go Toolchain Cmd Cgo
- Before 1.26.11; 1.27.0-0 to before 1.27.4
- Go Toolchain Cmd Compile
- Before 1.26.11; 1.27.0-0 to before 1.27.4
- Go Toolchain Cmd Link
- Before 1.26.11; 1.27.0-0 to before 1.27.4
Description
Building a malicious package that uses "//go:cgo_import_dynamic" or links against a crafted PE object on Windows could pass unsafe library arguments to the external linker. The compiler only checked the first character of the library name in "//go:cgo_import_dynamic" directives and skipped validation in cgo-generated files. In addition, on Windows, "cmd/cgo" and "cmd/link" did not validate imported DLL names extracted from PE object files before emitting "-l<name>" flags for the external linker, allowing a crafted DLL name containing ".." path traversal or special characters to reference arbitrary files on disk. The compiler now validates every character of the library name in "//go:cgo_import_dynamic" directives (including in cgo-generated files on Windows) and rejects ".." path traversal, and "cmd/cgo" and "cmd/link" reject PE imported DLL names containing path separators, "..", ":", or leading "-" or "@".
Affected products
Get alerts for these →Timeline 19
Latest change: Tenable Cloud Security plugin 499225: Alpine: multiple go packages: security update to 1.27.4-r0 (Dec 3, 2026)
News, advisories, exploit code, scanner detection and exploitation, newest first.
Yesterday
Fri, Nov 27, 2026
Wed, Nov 25, 2026
- DetectionNessus plugin 385941: RockyLinux 9 : golang (RLSA-2026:102586)Tenable
- DetectionNessus plugin 386035: RHEL 9 : golang (RHSA-2026:102586)Tenable
Tue, Nov 24, 2026
Sun, Nov 22, 2026
- DetectionNessus plugin 385105: openSUSE 16 Security Update : go1.26 (openSUSE-SU-2026:22407-1)Tenable
- DetectionNessus plugin 385126: openSUSE 16 Security Update : go1.27 (openSUSE-SU-2026:22374-1)Tenable
- DetectionNessus plugin 385127: openSUSE 16 Security Update : go1.26 (openSUSE-SU-2026:22386-1)Tenable
- DetectionNessus plugin 385129: openSUSE 16 Security Update : go1.27 (openSUSE-SU-2026:22405-1)Tenable
Wed, Nov 18, 2026
Sat, Nov 14, 2026
Wed, Nov 11, 2026
- CVECVE-2026-97042 published (CVSS 8.8)CVE Program · 05:19 UTC
Tue, Nov 10, 2026
References 4
- go.dev /cl/862155
- go.dev /issue/82568
- groups.google.com /g/golang-announce/c/iY8TY0wWgbM
- pkg.go.dev /vuln/GO-2026-6849