{"id":"CVE-2026-97041","aliases":["DEBIAN-CVE-2026-97041","EUVD-2026-123104","GHSA-537w-q924-jhpm","GO-2026-6850","openSUSE-SU-2026:12529-1"],"status":"published","title":"Host linker flag injection via //go:cgo_* directives in cmd/compile and cmd/link","description":"Building a malicious package containing \"//go:cgo_*\" compiler directives could inject arbitrary flags into the external linker invocation on ELF platforms. The compiler and linker did not reject commas in \"//go:cgo_import_dynamic\", \"//go:cgo_export_dynamic\", \"//go:cgo_export_static\", \"//go:cgo_import_static\", and \"//go:cgo_dynamic_linker\" directives, and the linker passed the dynamic linker path using \"-Wl,--dynamic-linker,\u003cpath\u003e\". Furthermore, the two-argument form of \"//go:cgo_import_dynamic\" (which is permitted in non-cgo Go source files) could overwrite the external symbol name of a symbol already marked for cgo export. A symbol name or dynamic linker path containing a comma or leading \"@\" could split \"-Wl,--export-dynamic-symbol=\" or \"-Wl,--dynamic-linker,\" into arbitrary host linker flags or response file arguments. The compiler and linker now reject commas in \"//go:cgo_*\" symbol and dynamic linker directives, the linker passes \"-Wl,--dynamic-linker=\u003cpath\u003e\", and \"cgo_import_dynamic\" no longer overwrites symbols exported via \"cgo_export_dynamic\" or \"cgo_export_static\".","epss":{"day":"2026-11-12","score":0.00234,"percentile":0.14452,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"published":"2026-11-11T00:00:00Z","modified":"2026-11-12T17:23:23Z","fixes":[{"ecosystem":"Go","package":"toolchain","fixed_in":["1.26.11","1.27.4"],"sources":["osv"]}],"affected":[{"source":"osv","ecosystem":"Debian:12","package":"golang-1.19","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.19.10-1","1.19.10-2","1.19.11-1","1.19.12-1","1.19.12-2","1.19.12-2~bpo11+1","1.19.12-2~bpo12+1","1.19.13-1","1.19.13-1~bpo11+1","1.19.13-1~bpo12+1","1.19.8-2","1.19.9-1"]},{"source":"osv","ecosystem":"Debian:13","package":"golang-1.24","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.24.12-1","1.24.13-1","1.24.13-2","1.24.4-1","1.24.4-2","1.24.4-3","1.24.4-4","1.24.7-1","1.24.8-1","1.24.9-1"]},{"source":"osv","ecosystem":"Debian:14","package":"golang-1.26","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.26.0-1","1.26.1-1","1.26.10-1","1.26.10-1~bpo13+1","1.26.11-1","1.26.2-1","1.26.2-2","1.26.2-3","1.26.3-1","1.26.3-1~bpo13+1","1.26.3-2","1.26.3-2~bpo13+1","1.26.4-1","1.26.4-1~bpo13+1","1.26.5-1","1.26.5-1~bpo13+1","1.26.6-1","1.26.6-2","1.26.7-1","1.26.7-1~bpo13+1","1.26.8-1","1.26.8-1~bpo13+1","1.26.8-2","1.26.9-1","1.26.9-1~bpo13+1","1.26~rc2-1","1.26~rc3-1","1.26~rc3-2"]},{"source":"osv","ecosystem":"Debian:14","package":"golang-1.27","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.27.0-1","1.27.0-1~bpo13+1","1.27.1-1","1.27.1-2","1.27.1-2~bpo13+1","1.27.2-1","1.27.2-1~bpo13+1","1.27.2-1~bpo13+2","1.27.3-1","1.27.3-1~bpo13+1","1.27.4-1","1.27~rc1-1","1.27~rc2-1","1.27~rc3-1"]},{"source":"osv","ecosystem":"Go","package":"toolchain","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"1.26.11"},{"introduced":"1.27.0-0"},{"fixed":"1.27.4"}]}]},{"source":"osv","ecosystem":"openSUSE:Tumbleweed","package":"go1.26","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.26.11-1.1"}]}],"bundled":12}],"products":[{"vendor":"go toolchain","product":"cmd/compile"},{"vendor":"go toolchain","product":"cmd/link"}],"references":[{"url":"https://go.dev/cl/862154","tags":["fix"]},{"url":"https://go.dev/issue/82569","tags":["report"]},{"url":"https://groups.google.com/g/golang-announce/c/iY8TY0wWgbM","tags":["web"]},{"url":"https://pkg.go.dev/vuln/GO-2026-6850"},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-97041"},{"url":"https://github.com/advisories/GHSA-537w-q924-jhpm"},{"url":"https://security-tracker.debian.org/tracker/CVE-2026-97041","tags":["advisory"]},{"url":"","tags":["advisory"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97033","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97034","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97035","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97036","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97037","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97038","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97039","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97040","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97041","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97042","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97043","tags":["web"]},{"url":"https://www.suse.com/security/cve/CVE-2026-97054","tags":["web"]}],"sources":{"cve":[{"id":"CVE-2026-97041","title":"Host linker flag injection via //go:cgo_* directives in cmd/compile and cmd/link","description":"Building a malicious package containing \"//go:cgo_*\" compiler directives could inject arbitrary flags into the external linker invocation on ELF platforms. The compiler and linker did not reject commas in \"//go:cgo_import_dynamic\", \"//go:cgo_export_dynamic\", \"//go:cgo_export_static\", \"//go:cgo_import_static\", and \"//go:cgo_dynamic_linker\" directives, and the linker passed the dynamic linker path using \"-Wl,--dynamic-linker,\u003cpath\u003e\". Furthermore, the two-argument form of \"//go:cgo_import_dynamic\" (which is permitted in non-cgo Go source files) could overwrite the external symbol name of a symbol already marked for cgo export. A symbol name or dynamic linker path containing a comma or leading \"@\" could split \"-Wl,--export-dynamic-symbol=\" or \"-Wl,--dynamic-linker,\" into arbitrary host linker flags or response file arguments. The compiler and linker now reject commas in \"//go:cgo_*\" symbol and dynamic linker directives, the linker passes \"-Wl,--dynamic-linker=\u003cpath\u003e\", and \"cgo_import_dynamic\" no longer overwrites symbols exported via \"cgo_export_dynamic\" or \"cgo_export_static\".","status":"published","published":"2026-11-11T03:13:15.269Z","modified":"2026-11-11T03:13:15.269Z","updated_at":"2026-11-11T04:22:54.647883Z"}],"euvd":[{"id":"EUVD-2026-123104","description":"Building a malicious package containing \"//go:cgo_*\" compiler directives could inject arbitrary flags into the external linker invocation on ELF platforms. The compiler and linker did not reject commas in \"//go:cgo_import_dynamic\", \"//go:cgo_export_dynamic\", \"//go:cgo_export_static\", \"//go:cgo_import_static\", and \"//go:cgo_dynamic_linker\" directives, and the linker passed the dynamic linker path using \"-Wl,--dynamic-linker,\u003cpath\u003e\". Furthermore, the two-argument form of \"//go:cgo_import_dynamic\" (which is permitted in non-cgo Go source files) could overwrite the external symbol name of a symbol already marked for cgo export. A symbol name or dynamic linker path containing a comma or leading \"@\" could split \"-Wl,--export-dynamic-symbol=\" or \"-Wl,--dynamic-linker,\" into arbitrary host linker flags or response file arguments. The compiler and linker now reject commas in \"//go:cgo_*\" symbol and dynamic linker directives, the linker passes \"-Wl,--dynamic-linker=\u003cpath\u003e\", and \"cgo_import_dynamic\" no longer overwrites symbols exported via \"cgo_export_dynamic\" or \"cgo_export_static\".","status":"published","published":"2026-11-11T03:13:15Z","modified":"2026-11-11T03:13:15Z","updated_at":"2026-11-11T08:27:52.334831Z"}],"ghsa":[{"id":"GHSA-537w-q924-jhpm","title":"Building a malicious package containing \"//go:cgo_*\" compiler directives could inject arbitrary...","description":"Building a malicious package containing \"//go:cgo_*\" compiler directives could inject arbitrary flags into the external linker invocation on ELF platforms. The compiler and linker did not reject commas in \"//go:cgo_import_dynamic\", \"//go:cgo_export_dynamic\", \"//go:cgo_export_static\", \"//go:cgo_import_static\", and \"//go:cgo_dynamic_linker\" directives, and the linker passed the dynamic linker path using \"-Wl,--dynamic-linker,\u003cpath\u003e\". Furthermore, the two-argument form of \"//go:cgo_import_dynamic\" (which is permitted in non-cgo Go source files) could overwrite the external symbol name of a symbol already marked for cgo export. A symbol name or dynamic linker path containing a comma or leading \"@\" could split \"-Wl,--export-dynamic-symbol=\" or \"-Wl,--dynamic-linker,\" into arbitrary host linker flags or response file arguments. The compiler and linker now reject commas in \"//go:cgo_*\" symbol and dynamic linker directives, the linker passes \"-Wl,--dynamic-linker=\u003cpath\u003e\", and \"cgo_import_dynamic\" no longer overwrites symbols exported via \"cgo_export_dynamic\" or \"cgo_export_static\".","status":"published","published":"2026-11-11T06:32:38Z","modified":"2026-11-11T06:32:39Z","updated_at":"2026-11-11T07:02:43.25695Z"}],"nvd":[{"id":"CVE-2026-97041","description":"Building a malicious package containing \"//go:cgo_*\" compiler directives could inject arbitrary flags into the external linker invocation on ELF platforms. The compiler and linker did not reject commas in \"//go:cgo_import_dynamic\", \"//go:cgo_export_dynamic\", \"//go:cgo_export_static\", \"//go:cgo_import_static\", and \"//go:cgo_dynamic_linker\" directives, and the linker passed the dynamic linker path using \"-Wl,--dynamic-linker,\u003cpath\u003e\". Furthermore, the two-argument form of \"//go:cgo_import_dynamic\" (which is permitted in non-cgo Go source files) could overwrite the external symbol name of a symbol already marked for cgo export. A symbol name or dynamic linker path containing a comma or leading \"@\" could split \"-Wl,--export-dynamic-symbol=\" or \"-Wl,--dynamic-linker,\" into arbitrary host linker flags or response file arguments. The compiler and linker now reject commas in \"//go:cgo_*\" symbol and dynamic linker directives, the linker passes \"-Wl,--dynamic-linker=\u003cpath\u003e\", and \"cgo_import_dynamic\" no longer overwrites symbols exported via \"cgo_export_dynamic\" or \"cgo_export_static\".","status":"published","published":"2026-11-11T05:19:58.417Z","modified":"2026-11-11T05:19:58.417Z","updated_at":"2026-11-11T07:23:51.781546Z"}],"osv":[{"id":"DEBIAN-CVE-2026-97041","description":"Building a malicious package containing \"//go:cgo_*\" compiler directives could inject arbitrary flags into the external linker invocation on ELF platforms. The compiler and linker did not reject commas in \"//go:cgo_import_dynamic\", \"//go:cgo_export_dynamic\", \"//go:cgo_export_static\", \"//go:cgo_import_static\", and \"//go:cgo_dynamic_linker\" directives, and the linker passed the dynamic linker path using \"-Wl,--dynamic-linker,\u003cpath\u003e\". Furthermore, the two-argument form of \"//go:cgo_import_dynamic\" (which is permitted in non-cgo Go source files) could overwrite the external symbol name of a symbol already marked for cgo export. A symbol name or dynamic linker path containing a comma or leading \"@\" could split \"-Wl,--export-dynamic-symbol=\" or \"-Wl,--dynamic-linker,\" into arbitrary host linker flags or response file arguments. The compiler and linker now reject commas in \"//go:cgo_*\" symbol and dynamic linker directives, the linker passes \"-Wl,--dynamic-linker=\u003cpath\u003e\", and \"cgo_import_dynamic\" no longer overwrites symbols exported via \"cgo_export_dynamic\" or \"cgo_export_static\".","status":"published","published":"2026-11-11T05:19:58.417Z","modified":"2026-11-11T07:47:45.276882389Z","updated_at":"2026-11-11T08:27:16.400656Z"},{"id":"GO-2026-6850","title":"Host linker flag injection via //go:cgo_* directives in cmd/compile and cmd/link","description":"Building a malicious package containing \"//go:cgo_*\" compiler directives could inject arbitrary flags into the external linker invocation on ELF platforms.\n\nThe compiler and linker did not reject commas in \"//go:cgo_import_dynamic\", \"//go:cgo_export_dynamic\", \"//go:cgo_export_static\", \"//go:cgo_import_static\", and \"//go:cgo_dynamic_linker\" directives, and the linker passed the dynamic linker path using \"-Wl,--dynamic-linker,\u003cpath\u003e\". Furthermore, the two-argument form of \"//go:cgo_import_dynamic\" (which is permitted in non-cgo Go source files) could overwrite the external symbol name of a symbol already marked for cgo export. A symbol name or dynamic linker path containing a comma or leading \"@\" could split \"-Wl,--export-dynamic-symbol=\" or \"-Wl,--dynamic-linker,\" into arbitrary host linker flags or response file arguments.\n\nThe compiler and linker now reject commas in \"//go:cgo_*\" symbol and dynamic linker directives, the linker passes \"-Wl,--dynamic-linker=\u003cpath\u003e\", and \"cgo_import_dynamic\" no longer overwrites symbols exported via \"cgo_export_dynamic\" or \"cgo_export_static\".","status":"published","published":"2026-11-11T02:51:11Z","modified":"2026-11-11T03:15:14.803931428Z","updated_at":"2026-11-11T03:52:51.074362Z"},{"id":"openSUSE-SU-2026:12529-1","title":"go1.26-1.26.11-1.1 on GA media","description":"These are all security issues fixed in the go1.26-1.26.11-1.1 package on the GA media of openSUSE Tumbleweed.","status":"published","published":"2026-11-11T00:00:00Z","modified":"2026-11-12T17:23:23.015967912Z","updated_at":"2026-11-12T18:02:05.26944Z"}]}}
