cve.bz

CVE-2025-61731

7.8 highEPSS 0.6%

High (7.8) in golang go. EPSS 0.6% chance of exploitation in the next 30 days. Fixed in toolchain 1.24.12, 1.25.6.

Building a malicious file with cmd/go can cause can cause a write to an attacker-controlled file with partial control of the file content. The "#cgo pkg-config:" directive in a Go source file provides command-line arguments to provide to the Go pkg-config command. An attacker can provide a "--log-file" argument to this directive, causing pkg-config to write to an attacker-controlled location.

Severity

CVSS 3.1

7.8 high
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
EPSS
0.6% chance of exploitation in the next 30 days; higher than 49% of CVEs (scores of 2026-10-31)
CWE
CWE-88
Published
Modified
Record from
the NVD, synced

Affected

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GO-2026-4339Gotoolchain<1.24.12
>=1.25.0 <1.25.6
1.24.12, 1.25.6

References

Check your stackJSON