Bug 2571450 (CVE-2026-97036) - CVE-2026-97036 cmd/go: golang: cmd/go: arbitrary code execution via crafted cgo linker flags
Summary: CVE-2026-97036 cmd/go: golang: cmd/go: arbitrary code execution via crafted c...
Keywords:
Status: NEW
Alias: CVE-2026-97036
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On: 2579832 2580065
Blocks:
TreeView+ depends on / blocked
 
Reported: 2026-11-11 03:21 UTC by OSIDB Bzimport
Modified: 2026-11-21 09:50 UTC (History)
28 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description OSIDB Bzimport 2026-11-11 03:21:52 UTC
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.


Note You need to log in before you can comment on or make changes to this bug.