GO-2025-3956

Unexpected paths returned from LookPath in os/exec

At a glance

Published
Updated
CVE
CVE-2025-47906
Aliases
BIT-golang-2025-47906

Description

If the PATH environment variable contains paths which are executables (rather than just directories), passing certain strings to LookPath ("", ".", and ".."), can result in the binaries listed in the PATH being unexpectedly returned.

Affected packages

PackageVersions
Go · stdlibintroduced 0, fixed 1.23.12, introduced 1.24.0, fixed 1.24.6

References

Sources

SourceLicence
OSV.devCC-BY 4.0 — Go Vulnerability Database