GO-2024-2825

Source
https://pkg.go.dev/vuln/GO-2024-2825
Import Source
https://vuln.go.dev/ID/GO-2024-2825.json
JSON Data
https://api.test.osv.dev/v1/vulns/GO-2024-2825
Aliases
Published
2024-05-08T15:17:04Z
Modified
2024-10-15T05:42:09.738603Z
Summary
Arbitrary code execution during build on Darwin in cmd/go
Details

On Darwin, building a Go module which contains CGO can trigger arbitrary code execution when using the Apple version of ld, due to usage of the -lto_library flag in a "#cgo LDFLAGS" directive.

Database specific
{
    "review_status": "REVIEWED",
    "url": "https://pkg.go.dev/vuln/GO-2024-2825"
}
References
Credits
    • Juho Forsén (Mattermost)

Affected packages

Go / toolchain

Package

Affected ranges

Type
SEMVER
Events
Introduced
0Unknown introduced version / All previous versions are affected
Fixed
1.21.10
Introduced
1.22.0-0
Fixed
1.22.3

Ecosystem specific

{
    "imports": [
        {
            "path": "cmd/go",
            "goos": [
                "darwin"
            ]
        }
    ]
}