CVE-2025-61731Golang Go
High 7.8
Follow: this CVE · Golang · Golang Go We alert you by email or Slack (account required).
- Priority
- 47
- CVSS 3.1
- 7.8
- EPSS
- —
- Auth required
- Yes
- Published
- Jan 28, 2026
- Updated
- Sep 10, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-88
- SSVC (CISA)
- Exploitation: none · Automatable: no · Technical impact: total
- Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
What happens
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.
What to do
- Apply the vendor's security update for Go.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| Go | toolchain |
< 1.24.12 |
1.24.12 |
go get toolchain@v1.24.12 |
| Go | toolchain |
≥ 1.25.0 < 1.25.6 |
1.25.6 |
go get toolchain@v1.25.6 |
Per OSV / GitHub Advisories (GO-2026-4339). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| golang | go | < 1.24.12 |
| golang | go | ≥ 1.25.0 < 1.25.6 |
Official advisories
- Red Hat Security Advisory: go-toolset:rhel8 security update · Red Hat · RHSA-2026:7876 · Aug 5, 2026 High
- Security update for govulncheck-vulndb · SUSE · openSUSE-SU-2026:21483-1 · Jul 30, 2026 Critical
- Red Hat Security Advisory: Red Hat Hardened Images RPMs bug fix and enhancement update · Red Hat · RHSA-2026:7385 · May 15, 2026 Critical
- Red Hat Security Advisory: Red Hat Hardened Images RPMs bug fix and enhancement update · Red Hat · RHSA-2026:7291 · May 14, 2026 Critical
- Security update for coredns · SUSE · openSUSE-SU-2026:20619-1 · Apr 23, 2026 Critical
- Security update for go1.24-openssl · SUSE · SUSE-SU-2026:20629-1 · Mar 3, 2026 Critical
Also: Red Hat (+11), SUSE (+16)
Vendor, CERT and distribution advisories that name this CVE. Original titles.
Official sources
References
Links published by the sources. Open them with care.
- go.dev Patch
- go.dev Issue Tracking
- groups.google.com Mailing List Release Notes
- pkg.go.dev Vendor Advisory
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- access.redhat.com
- bugzilla.redhat.com
- security.access.redhat.com