Skip to content
High 8.8

Go言語のcmd/goにcgoの脆弱性、ビルド時に任意のコードを実行されるおそれ

CVE-2026-97036 First seen on SecPulse

Summary

macOS(Darwin)でcgoを使うパッケージを悪意のあるものでビルドすると、Appleのリンカーを通じて任意のコードが実行されるおそれがあります。影響を受けるのはGo toolchain(cmd/go)の1.26.11より前と、1.27.0以降1.27.4より前の版です。修正版の1.26.11または1.27.4への更新が必要です。

AI summary

Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.

macOS(Darwin)でcgoを使うパッケージを悪意のあるものでビルドすると、Appleのリンカーを通じて任意のコードが実行されるおそれがあります。影響を受けるのはGo toolchain(cmd/go)の1.26.11より前と、1.27.0以降1.27.4より前の版です。修正版の1.26.11または1.27.4への更新が必要です。

Affected packages

PackageAffected → Fixed
Go toolchaincmd/go
< 1.26.11→ 1.26.11
≥ 1.27.0-0, < 1.27.4→ 1.27.4
Gotoolchain
< 1.26.11→ 1.26.11
≥ 1.27.0-0, < 1.27.4→ 1.27.4
Bitnamigolang
< 1.26.11→ 1.26.11
≥ 1.27.0-0, < 1.27.4→ 1.27.4

Fix status by distribution

Records published by each distribution for this CVE. Fixed versions differ by release; check each link.

Original description The description as published by the source.

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 " 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.

Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details