Building a malicious file with cmd/go can cause can cause a write to an attacker-controlled file with partial…
Historical advisory recorded 25 Oct 2026 03:17:27 UTC. Read the latest advisory.
nvd · CVE-2025-61731
PublishedBuilding 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.
Read the publisher's advisoryAffected versions, risk and source history
nvd · CVE-2025-61731
PublishedNVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON.
Source analysis status: Modified
Weakness classifications: NVD-CWE-noinfo · CWE-88
Original publisher date fields
published: 2026-01-28T20:16:10.073
lastModified: 2026-09-10T13:17:10.037
1 source CPE criteria · context only
- cpe:2.3:a:golang:go:*:*:*:*:*:*:*:*
The original JSON retains the logical configuration operators, exclusions and version bounds.
No normalized affected-package data is projected for this source revision. The original publisher record may contain additional product and version evidence; this does not establish that a package is unaffected.
Original source record · Cite this exact observation · Complete original publisher JSON