{"id":"BIT-golang-2026-97036","summary":"Arbitrary code execution during build on darwin via \"-l to_library\" in cgo in cmd/go","details":"On Darwin, building a malicious package that uses cgo could cause arbitrary code execution when using the Apple linker due to passing \"-l to_library \u003cpath\u003e\" in a \"#cgo LDFLAGS\" directive. The Apple linker recombines the separated arguments \"-l\" and \"to_library\" into \"-lto_library\", which loads an arbitrary LTO plugin dynamic library at link time. The go command now disallows \"-l\" followed by \"to_library\" in \"#cgo LDFLAGS\", rejects \"-lazy_library\", \"-lazy_framework\", \"-load_hidden\", \"-library\", and \"-library-path\", and checks recombined \"-l\" arguments against disallowed linker flags and patterns.","aliases":["CVE-2026-97036","GO-2026-6855"],"modified":"2026-11-27T06:55:56.208280660Z","published":"2026-11-27T05:44:07.442Z","database_specific":{"severity":"High","cpes":["cpe:2.3:a:golang:go:*:*:*:*:*:*:*:*"]},"references":[{"type":"WEB","url":"https://go.dev/cl/862149"},{"type":"WEB","url":"https://go.dev/issue/82574"},{"type":"WEB","url":"https://groups.google.com/g/golang-announce/c/iY8TY0wWgbM"},{"type":"WEB","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-97036"},{"type":"WEB","url":"https://pkg.go.dev/vuln/GO-2026-6855"}],"affected":[{"package":{"name":"golang","ecosystem":"Bitnami","purl":"pkg:bitnami/golang"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"1.26.11"},{"introduced":"1.27.0-0"},{"fixed":"1.27.4"}]}],"database_specific":{"source":"https://github.com/bitnami/vulndb/tree/main/data/golang/BIT-golang-2026-97036.json"},"severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H"}]}],"schema_version":"1.9.2"}