Skip to content
CVE PROGRAM SOURCE RECORDUnscored

CVE-2023-39320

Arbitrary code execution via go.mod toolchain directive in cmd/go

Description

The go.mod toolchain directive, introduced in Go 1.21, can be leveraged to execute scripts and binaries relative to the root of the module when the "go" command was executed within the module. This applies to modules downloaded using the "go" command from the module proxy, as well as modules downloaded directly using VCS software.

Affected products

Version statuses are supplied by the assigning organization. Consult the original record for detailed ranges and platform conditions.

Go toolchain cmd/go

Default version status: unaffected

  • 1.21.0-0 to < 1.21.1affected

References