AZL-113576: CVE-2026-97040 affecting package python-tensorboard 2.16.2-6
Building a package containing a crafted ".syso" file could bypass cgo flag validation and inject arbitrary linker flags when linking. When loading ".syso" entries from a package archive, the linker only checked for recognized host object headers (ELF, Mach-O, PE, and XCOFF) before falling through to Go object parsing. A ".syso" file beginning with a "go object" header was parsed as a Go compiler object, allowing untrusted cgo metadata directives (such as "cgoldflag" or "cgodynamiclinker") embedded in the ".syso" file to be passed to the external linker without validation. Additionally, ".syso" filenames longer than 16 bytes lost their ".syso" extension when truncated in archive headers, and unrecognized ".syso" formats forced external linking in pure-Go builds. The linker now rejects ".syso" files that are not recognized host object formats, and "cmd/go" and "cmd/pack" preserve the ".syso" suffix when truncating long archive member names.
Affected Software
Event History
Frequently Asked Questions
What does an attacker need to exploit this issue?
An attacker would need to cause a package build to include a crafted .syso file. The malicious file can contain a Go object header and untrusted cgo metadata directives that are passed as arbitrary linker flags during linking.
Are pure-Go builds affected?
Yes. An unrecognized .syso format could force external linking even in pure-Go builds. The issue is specifically triggered while the linker loads .syso entries from a package archive.
What mitigations are available if an update cannot be applied immediately?
Avoid building packages that include untrusted or unreviewed .syso files. In particular, inspect package archives and build inputs for .syso members that could contain Go object data or cgo linker directives.
How can I identify potentially affected build inputs?
Review package archives for .syso entries, including long filenames whose suffix may have been truncated in archive headers. Treat .syso files that are not recognized ELF, Mach-O, PE, or XCOFF host objects as suspicious.