CVE-2026-97036
High 8.8No known exploitationFix availableArbitrary code execution during build on darwin via "-l to_library" in cgo in cmd/go
Record last updated
CVSS score
High on a 0 to 10 scale
EPSS, chance of exploitation in 30 days
Higher than 46% of scored CVEs. A prediction, not evidence.
CISA remediation deadline
Not in the KEV catalog
Description
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 <path>" 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.
Weakness: CWE-88
Patching and mitigation
- Patch status
- Fix available (source: Microsoft MSRC)
- Fix documented (source date)
- Mitigation
- None documented
- Vendor guidance
- msrc.microsoft.com (opens in a new tab)
Affected products
| Vendor | Product | Affected versions | Fixed in | Per |
|---|---|---|---|---|
| Microsoft | azl3 golang 1.26.10-1 on Azure Linux 3.0 | Not documented | Not documented | Microsoft MSRC |
| Microsoft | azl3 golang 1.26.11-1 on Azure Linux 3.0 | Not documented | Not documented | Microsoft MSRC |
| Microsoft | azl3 golang 1.27.3-1 on Azure Linux 3.0 | Not documented | Not documented | Microsoft MSRC |
| Microsoft | azl3 golang 1.27.4-1 on Azure Linux 3.0 | Not documented | Not documented | Microsoft MSRC |
| Microsoft | azl4 cross-gcc 15.2.1-1.azl4 on Azure Linux 4.0 | Not documented | Not documented | Microsoft MSRC |
| Microsoft | azl4 gcc 15.3.1-2.azl4 on Azure Linux 4.0 | Not documented | Not documented | Microsoft MSRC |
| Microsoft | azl4 golang 1.26.10-3.azl4 on Azure Linux 4.0 | Not documented | Not documented | Microsoft MSRC |
Timeline
Advisory
Microsoft advisory published
Advisory change
Microsoft advisory revised (2.0): Information published.
Advisory change
Microsoft advisory revised (3.0): Information published.
Advisory change
Microsoft advisory revised (4.0): Information published.
Patch
Fix documented by Microsoft MSRC