{"id":"CVE-2026-97034","published":"2026-11-11T03:13:17Z","modified":"2026-11-17T04:55:30Z","title":"Arbitrary command execution via GCC spec files in cgo linker search directories in cmd/go","vendor":"Go toolchain","product":"cmd/go","tier":"tail","description":{"text":"When using GCC, building a malicious package that uses cgo could cause arbitrary command execution at link time via untrusted GCC spec files (\"specs\" or \"*.spec\"). When linking with \"-fopenmp\", \"-fopenacc\", or \"-fsanitize=\" in \"#cgo LDFLAGS\", GCC's built-in link spec evaluates \"%:include(libgomp.spec)\" or \"%:include(libsanitizer.spec)\" and searches for spec files in \"-L\" and sysroot directories (including subdirectories and multilib sibling directories such as \"../lib64\"), as well as the working directory when \"-fopenmp\" or \"-fopenacc\" is used or when \"-fsanitize=\" is combined with \"-static\" or \"-static-lib*\". The go command now rejects \"-L\", \"-isysroot\", and \"-Wl,-syslibroot\" directories (and the working and package directories when applicable) that contain GCC spec files, and disallows \"@\" and \"-\" prefixes in \"-fsanitize=\" compiler flag values.","provenance":"source","from":"CVE.org"},"cvss":{"score":8.8,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","provenance":"source","from":"CISA ADP Vulnrichment"},"epss":{"score":0.00828,"percentile":0.58398,"provenance":"source"},"cwes":[{"id":"CWE-77","name":"Improper Neutralization of Special Elements used in a Command"}],"references":[{"url":"https://go.dev/cl/862147","tags":[]},{"url":"https://go.dev/issue/82576","tags":[]},{"url":"https://groups.google.com/g/golang-announce/c/iY8TY0wWgbM","tags":[]},{"url":"https://pkg.go.dev/vuln/GO-2026-6857","tags":[]}],"priority":{"score":17.8,"factors":[{"name":"EPSS percentile","points":11.68},{"name":"CVSS severity","points":6.16}]},"vendorSlug":"go-toolchain","affectedVersions":[{"vendor":"Go toolchain","product":"cmd/go","versions":["< 1.26.11",">= 1.27.0-0, < 1.27.4"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"total","timestamp":"2026-11-16T00:00:00+00:00","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Go","package":"toolchain","vulnerableRanges":["<1.26.11",">=1.27.0-0, <1.27.4"],"patched":["1.26.11","1.27.4"],"from":["GO-2026-6857"],"provenance":"source"}],"euvd":{"id":"EUVD-2026-123111","exploited":false,"provenance":"source"}}