CVE-2026-97040
Go Toolchain cmd/go code injection in cmd/link via disguised .syso files
An attacker can inject unchecked linker flags into a build by hiding a crafted file as an object file.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Fuente: CISA-ADP
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Divulgación | Publicada | CVE-2026-97040 divulgada · CVSS 9.8 (CISA-ADP) | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Fuente: OSV | Registro visto por primera vez en OSV | |
| Monitoreo | Fuente: NIST NVD | Registro visto por primera vez en NIST NVD | |
| Divulgación | Evaluación SSVC | CISA-ADP · explotación ninguna | |
| Divulgación | Modificada | Última actualización del registro | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
The Go toolchain (the `cmd/go` and `cmd/link` tools) can be made to pass unvalidated linker flags when building a package that contains a crafted ".syso" file disguised as a Go object file. This lets an attacker embed cgo directives such as "cgo_ldflag" that are forwarded to the external linker without checks.
Descripción original del registro (Go)
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 "cgo_ldflag" or "cgo_dynamic_linker") 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.
Condiciones y alcance
Desglose de métricas
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
cmd/go |
Corregida | 1.26.11, 1.27.4 | — | — |
1.26.111.27.4Arsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://go.dev/cl/862153https://go.dev/issue/82570https://groups.google.com/g/golang-announce/c/iY8TY0wWgbMhttps://pkg.go.dev/vuln/GO-2026-6851Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
