VDB

CVE-2023-29402

CVE-2023-29402 PUBLISHED CVSS 9.8 CRITICAL

Code injection via go command with cgo in cmd/go

Reported by go · Published June 8, 2023

The go command may generate unexpected code at build time when using cgo. This may result in unexpected behavior when running a go program which uses cgo. This may occur when running an untrusted module which contains directories with newline characters in their names. Modules which are retrieved using the go command, i.e. via "go get", are not affected (modules retrieved using GOPATH-mode, i.e. GO111MODULE=off, may be affected).

Fixed versions

Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.

PackageEcosystemFixed in
toolchainGo Modules1.20.5, 1.19.10
cmd/goGo Modules1.20.5, 1.19.10
golangAmazon Linux1.20.5-1.amzn2023.0.2, 1.18.9-1.amzn2.0.6
golang-sharedAmazon Linux1.20.5-1.amzn2023.0.2, 1.18.9-1.amzn2.0.6
kubeflow-katibWolfi0.19.0-r40, 0.19.0-r31
golang-srcAmazon Linux1.20.5-1.amzn2023.0.2, 1.18.9-1.amzn2.0.6
falcoWolfi0.37.1-r0
kindChainguard0.21.0-r0
goAlpine1.20.5-r0
golang-miscAmazon Linux1.20.5-1.amzn2023.0.2, 1.18.9-1.amzn2.0.6
golang-testsAmazon Linux1.20.5-1.amzn2023.0.2, 1.18.9-1.amzn2.0.6
golang-docsAmazon Linux1.20.5-1.amzn2023.0.2, 1.18.9-1.amzn2.0.6

10 more packages have a fixed version. See every fix in Lookup.

Risk scores

CVSS 3.1
9.8
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Affected products

VendorProductVersions
Go toolchaincmd/go0, 1.20.0-0
amazon:2023golang0
amazon:2golang-shared0
wolfikubeflow-katib0, 0
amazon:2023golang-src0
wolfifalco0
chainguardkind0
alpinego0
amazon:2golang-misc0
amazon:2023golang-tests0
amazon:2023golang-docs0
amazon:2golang0
amazon:2023golang-bin0
amazon:2golang-race0
amazon:2golang-tests0
chainguardpolicy-controller0
amazon:2golang-bin0
amazon:2023golang-misc0
Go toolchaincmd/go1.20.0-0, 0
amazon:2023golang-shared0

…and 6 more

Timeline

  • Jun 6, 2023 CVE Published
  • Jun 9, 2023 EPSS Score (30 in total, the first dated here)
  • Feb 8, 2024 PoC Published
  • Feb 17, 2026 Security Advisory (10 in total, the first dated here)
  • Nov 22, 2026 Distribution Patch (6 in total, the first dated here)

Query this with the API

The same record, from the CLI:

vulnetix vdb vuln CVE-2023-29402
vulnetix vdb fixes CVE-2023-29402

Or with curl, using the org id and key from your account page:

curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
  "https://api.vdb.vulnetix.com/v2/vuln/CVE-2023-29402/fixes/registry"

The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart

Look up in the Resolve Platform →
$ Lookup Community · 50/day Open Lookup ›