CVE-2025-61731 Arbitrary file write using cgo pkg-config directive in cmd/go
HighCVSS 8.6
EPSS 0.61%
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- No known exploitation · automatable: no · technical impact: total
- Technology
- UbuntuDebianRed Hat
Description
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.
Upgrade path
1766 packages: 26 fixed, 1 partially fixed, 1739 with no fix yet.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| azure linux golang(Azure Linux 3.0) | All versions | No fix listed | No fix yet |
| debian/golang-1.19(Debian 12) | = 1.19.8-2; = 1.19.9-1; = 1.19.10-1; = 1.19.10-2 +9 more | No fix listed | No fix yet |
| debian/golang-1.24(Debian 13) | = 1.24.4-1; = 1.24.4-2; = 1.24.4-3; = 1.24.4-4 +7 more | No fix listed | No fix yet |
| redhat container native virtualization | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8020020260408140623.02f7cb7a(Red Hat rhel_aus 8.2) | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8040020260408080443.5081a262(Red Hat rhel_aus 8.4) | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8040020260408080443.5081a262(Red Hat rhel_eus_long_life 8.4) | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8060020260409063558.97d7f71f(Red Hat rhel_aus 8.6) | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8060020260409063558.97d7f71f(Red Hat rhel_e4s 8.6) | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8060020260409063558.97d7f71f(Red Hat rhel_tus 8.6) | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8080020260331223648.6b4b45d8(Red Hat rhel_e4s 8.8) | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8080020260331223648.6b4b45d8(Red Hat rhel_tus 8.8) | All versions | No fix listed | No fix yet |
| redhat/go-toolset:rhel8-8100020260402232122.a3795dee(Red Hat enterprise_linux 8) | All versions | No fix listed | No fix yet |
| redhat/golang(Red Hat enterprise_linux 8) | All versions | No fix listed | No fix yet |
| redhat/openshift-golang-builder-container(Red Hat container_native_virtualization 4) | All versions | No fix listed | No fix yet |
| redhat/openshift-golang-builder-container(Red Hat service_mesh 2) | All versions | No fix listed | No fix yet |
| redhat/openshift-golang-builder-container(Red Hat service_mesh 3) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-cni-rhel8:1771992208(Red Hat service_mesh 2.6 el8) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-cni-rhel9:1774037349(Red Hat service_mesh 3.1 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-cni-rhel9:1774206585(Red Hat service_mesh 3.2 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-cni-rhel9:1774214116(Red Hat service_mesh 3.0 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-pilot-rhel9:1774006090(Red Hat service_mesh 3.0 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-pilot-rhel9:1774037369(Red Hat service_mesh 3.1 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-pilot-rhel9:1774206464(Red Hat service_mesh 3.2 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-proxyv2-rhel9:1774068855(Red Hat service_mesh 3.0 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-proxyv2-rhel9:1774114903(Red Hat service_mesh 3.2 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-proxyv2-rhel9:1774244136(Red Hat service_mesh 3.1 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-rhel8-operator:1771992461(Red Hat service_mesh 2.6 el8) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-rhel9-operator:1774293851(Red Hat service_mesh 3.1 el9) | All versions | No fix listed | No fix yet |
| redhat/openshift-service-mesh/istio-rhel9-operator:1774294372(Red Hat service_mesh 3.0 el9) | All versions | No fix listed | No fix yet |
… and 1,736 more packages.
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| azure linux golang(Azure Linux:3.0) | All versions | No fix listed |
| toolchain(Go) | < 1.24.12 | 1.24.12 |
| toolchain(Go) | >= 1.25.0, < 1.25.6 | 1.25.6 |
| debian/golang-1.19(Debian:12) | All versions | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.10-1 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.10-2 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.11-1 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.12-1 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.12-2 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.12-2~bpo11+1 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.12-2~bpo12+1 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.13-1 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.13-1~bpo11+1 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.13-1~bpo12+1 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.8-2 | No fix listed |
| debian/golang-1.19(Debian:12) | = 1.19.9-1 | No fix listed |
| debian/golang-1.24(Debian:13) | All versions | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.12-1 | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.13-1 | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.13-2 | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.4-1 | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.4-2 | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.4-3 | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.4-4 | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.7-1 | No fix listed |
Show 175 more
| Product | Affected versions | Fixed in |
|---|---|---|
| debian/golang-1.24(Debian:13) | = 1.24.8-1 | No fix listed |
| debian/golang-1.24(Debian:13) | = 1.24.9-1 | No fix listed |
| cmd/go(Go) | < 1.24.12 | 1.24.12 |
| cmd/go(Go) | >= 1.25.0, < 1.25.6 | 1.25.6 |
| redhat enterprise linux | < 0:1.25.8-1.el10_1 | 0:1.25.8-1.el10_1 |
| redhat enterprise linux eus | < 0:1.25.8-1.el10_0 | 0:1.25.8-1.el10_0 |
| redhat enterprise linux | < 8100020260402232122.a3795dee | 8100020260402232122.a3795dee |
| redhat rhel aus | < 8020020260408140623.02f7cb7a | 8020020260408140623.02f7cb7a |
| redhat rhel aus | < 8040020260408080443.5081a262 | 8040020260408080443.5081a262 |
| redhat rhel eus long life | < 8040020260408080443.5081a262 | 8040020260408080443.5081a262 |
| redhat rhel aus | < 8060020260409063558.97d7f71f | 8060020260409063558.97d7f71f |
| redhat rhel tus | < 8060020260409063558.97d7f71f | 8060020260409063558.97d7f71f |
| redhat rhel e4s | < 8060020260409063558.97d7f71f | 8060020260409063558.97d7f71f |
| redhat rhel tus | < 8080020260331223648.6b4b45d8 | 8080020260331223648.6b4b45d8 |
| redhat rhel e4s | < 8080020260331223648.6b4b45d8 | 8080020260331223648.6b4b45d8 |
| redhat enterprise linux | < 0:1.25.8-1.el9_7 | 0:1.25.8-1.el9_7 |
| redhat rhel e4s | < 0:1.17.13-11.el9_0 | 0:1.17.13-11.el9_0 |
| redhat rhel e4s | < 0:1.19.13-24.el9_2 | 0:1.19.13-24.el9_2 |
| redhat rhel eus | < 0:1.21.13-15.el9_4 | 0:1.21.13-15.el9_4 |
| redhat rhel eus | < 0:1.25.8-1.el9_6 | 0:1.25.8-1.el9_6 |
| redhat hummingbird | < 1.26.2-1.hum1 | 1.26.2-1.hum1 |
| redhat hummingbird | < 1.25.9-1.hum1 | 1.25.9-1.hum1 |
| redhat openshift | < 1777002694 | 1777002694 |
| redhat openshift | < 1777001625 | 1777001625 |
| redhat openshift | < 1777001562 | 1777001562 |
| redhat openshift | < 1777002936 | 1777002936 |
| redhat openshift | < 1777042122 | 1777042122 |
| redhat openshift | < 1777001567 | 1777001567 |
| redhat openshift | < 1777002279 | 1777002279 |
| redhat openshift | < 1777002206 | 1777002206 |
| redhat openshift | < 1777001821 | 1777001821 |
| redhat openshift | < 1777002716 | 1777002716 |
| redhat openshift | < 1777001592 | 1777001592 |
| redhat openshift | < 1777001811 | 1777001811 |
| redhat openshift | < 1777001595 | 1777001595 |
| redhat openshift | < 1777001647 | 1777001647 |
| redhat openshift | < 1777001622 | 1777001622 |
| redhat openshift | < 1777001637 | 1777001637 |
| redhat openshift | < 1777001993 | 1777001993 |
| redhat openshift | < 1777002058 | 1777002058 |
| redhat openshift | < 1777001588 | 1777001588 |
| redhat openshift | < 1777002145 | 1777002145 |
| redhat openshift | < 1777002709 | 1777002709 |
| redhat openshift | < 1777001819 | 1777001819 |
| redhat openshift | < 1777001657 | 1777001657 |
| redhat openshift | < 1777001578 | 1777001578 |
| redhat openshift | < 1777001593 | 1777001593 |
| redhat openshift | < 1777002721 | 1777002721 |
| redhat openshift | < 1777001896 | 1777001896 |
| redhat openshift | < 1777001576 | 1777001576 |
| redhat openshift | < 1777001621 | 1777001621 |
| redhat openshift | < 1777001630 | 1777001630 |
| redhat openshift | < 1776999989 | 1776999989 |
| redhat openshift | < 1777002317 | 1777002317 |
| redhat openshift | < 1777001736 | 1777001736 |
| redhat openshift | < 1777002062 | 1777002062 |
| redhat openshift | < 1777001639 | 1777001639 |
| redhat openshift | < 1777001616 | 1777001616 |
| redhat openshift | < 1777001722 | 1777001722 |
| redhat openshift | < 1777001579 | 1777001579 |
| redhat openshift | < 1777001660 | 1777001660 |
| redhat openshift | < 1777001584 | 1777001584 |
| redhat openshift | < 1777001860 | 1777001860 |
| redhat openshift | < 1777001846 | 1777001846 |
| redhat openshift | < 1777001876 | 1777001876 |
| redhat openshift | < 1777001943 | 1777001943 |
| redhat openshift | < 1777001599 | 1777001599 |
| redhat openshift | < 1777001611 | 1777001611 |
| redhat openshift | < 1777001561 | 1777001561 |
| redhat openshift | < 1777001575 | 1777001575 |
| redhat openshift | < 1777001571 | 1777001571 |
| redhat openshift | < 1777002164 | 1777002164 |
| redhat openshift | < 1777001580 | 1777001580 |
| redhat openshift | < 1777001813 | 1777001813 |
| redhat openshift | < 1777001698 | 1777001698 |
| redhat openshift | < 1777002719 | 1777002719 |
| redhat openshift | < 1777001569 | 1777001569 |
| redhat openshift | < 1777001603 | 1777001603 |
| redhat openshift | < 1777001612 | 1777001612 |
| redhat openshift | < 1777001775 | 1777001775 |
| redhat openshift | < 1777001570 | 1777001570 |
| redhat openshift | < 1777001574 | 1777001574 |
| redhat openshift | < 1777001558 | 1777001558 |
| redhat openshift | < 1777001608 | 1777001608 |
| redhat openshift | < 1777002039 | 1777002039 |
| redhat openshift | < 1777001653 | 1777001653 |
| redhat openshift | < 1777001577 | 1777001577 |
| redhat openshift | < 1777001777 | 1777001777 |
| redhat openshift | < 1777001656 | 1777001656 |
| redhat openshift | < 1777001606 | 1777001606 |
| redhat openshift | < 1777001646 | 1777001646 |
| redhat openshift | < 1776999972 | 1776999972 |
| redhat openshift | < 1776999948 | 1776999948 |
| redhat openshift | < 1776999951 | 1776999951 |
| redhat openshift | < 1776999947 | 1776999947 |
| redhat openshift | < 1776999949 | 1776999949 |
| redhat openshift | < 1777001741 | 1777001741 |
| redhat openshift | < 1777001992 | 1777001992 |
| redhat openshift | < 1777001681 | 1777001681 |
| redhat openshift | < 1777001596 | 1777001596 |
| redhat openshift | < 1777001898 | 1777001898 |
| redhat openshift | < 1777002697 | 1777002697 |
| redhat openshift | < 1777001692 | 1777001692 |
| redhat openshift | < 1777001837 | 1777001837 |
| redhat openshift | < 1777304752 | 1777304752 |
| redhat openshift | < 1777001784 | 1777001784 |
| redhat openshift | < 1777001854 | 1777001854 |
| redhat openshift | < 1777001888 | 1777001888 |
| redhat openshift | < 1777001586 | 1777001586 |
| redhat openshift | < 1777002168 | 1777002168 |
| redhat openshift | < 1777001585 | 1777001585 |
| redhat openshift | < 1777000374 | 1777000374 |
| redhat openshift | < 1777003222 | 1777003222 |
| redhat openshift | < 1777001763 | 1777001763 |
| redhat openshift | < 1777001618 | 1777001618 |
| redhat openshift | < 1777001642 | 1777001642 |
| redhat openshift | < 1776999981 | 1776999981 |
| redhat openshift | < 1777001815 | 1777001815 |
| redhat openshift | < 1777001549 | 1777001549 |
| redhat openshift | < 1777001541 | 1777001541 |
| redhat openshift | < 1777001659 | 1777001659 |
| redhat openshift | < 1777001636 | 1777001636 |
| redhat openshift | < 1777001598 | 1777001598 |
| redhat openshift | < 1777002732 | 1777002732 |
| redhat openshift | < 1777001535 | 1777001535 |
| redhat openshift | < 1777001628 | 1777001628 |
| redhat openshift | < 1777000645 | 1777000645 |
| redhat openshift | < 1777002718 | 1777002718 |
| redhat openshift | < 1777001624 | 1777001624 |
| redhat openshift | < 1777002057 | 1777002057 |
| redhat openshift | < 1777002725 | 1777002725 |
| redhat openshift | < 1777001617 | 1777001617 |
| redhat openshift | < 1777001581 | 1777001581 |
| redhat openshift | < 1777001573 | 1777001573 |
| redhat openshift | < 1777001671 | 1777001671 |
| redhat openshift | < 1777001649 | 1777001649 |
| redhat openshift | < 1777002178 | 1777002178 |
| redhat openshift | < 1777001818 | 1777001818 |
| redhat openshift | < 1777304565 | 1777304565 |
| redhat openshift | < 1777001521 | 1777001521 |
| redhat openshift | < 1777001566 | 1777001566 |
| redhat openshift | < 1777001771 | 1777001771 |
| redhat openshift | < 1777042146 | 1777042146 |
| redhat openshift | < 1777001745 | 1777001745 |
| redhat openshift | < 1777001893 | 1777001893 |
| redhat openshift | < 1777002720 | 1777002720 |
| redhat openshift | < 1777001726 | 1777001726 |
| redhat openshift | < 1777001790 | 1777001790 |
| redhat openshift | < 1777001589 | 1777001589 |
| redhat openshift | < 1777001614 | 1777001614 |
| redhat openshift | < 1777002345 | 1777002345 |
| redhat openshift | < 1778173182 | 1778173182 |
| redhat openshift | < 1777001839 | 1777001839 |
| redhat openshift | < 1777001605 | 1777001605 |
| redhat openshift | < 1777001655 | 1777001655 |
| redhat openshift | < 1777001823 | 1777001823 |
| redhat openshift | < 1777001631 | 1777001631 |
| redhat openshift | < 1777001640 | 1777001640 |
| redhat openshift | < 1777001645 | 1777001645 |
| redhat openshift | < 1779864120 | 1779864120 |
| redhat openshift | < 1779864235 | 1779864235 |
| redhat openshift | < 1779864128 | 1779864128 |
| redhat openshift | < 1779313037 | 1779313037 |
| redhat openshift | < 1779889676 | 1779889676 |
| redhat openshift | < 1779889641 | 1779889641 |
| redhat openshift | < 1778765353 | 1778765353 |
| redhat openshift | < 1778765274 | 1778765274 |
| redhat openshift | < 1779889723 | 1779889723 |
| redhat openshift | < 1779863997 | 1779863997 |
| redhat openshift | < 1779864079 | 1779864079 |
| redhat openshift | < 1779864508 | 1779864508 |
| redhat openshift | < 1779864192 | 1779864192 |
| redhat openshift | < 1779889720 | 1779889720 |
| redhat openshift | < 1779863999 | 1779863999 |
| redhat openshift | < 1779889660 | 1779889660 |
References
- MSRC Security Update Guide vendor-advisory
- Security Update patch
- go.dev patch
- go.dev issue-tracking
- groups.google.com mailing-list release-notes
- Debian Security Tracker CVE-2025-61731 vendor-advisory
- pkg.go.dev vendor-advisory
- Red Hat CVE page mitigation vdb-entry vendor-advisory
- RHBZ#2434433 issue-tracking
- security.access.redhat.com
- RHSA-2026:5943 patch vendor-advisory
- RHSA-2026:5941 patch vendor-advisory
- RHSA-2026:6949 patch vendor-advisory
- RHSA-2026:7878 patch vendor-advisory
- RHSA-2026:7879 patch vendor-advisory
- RHSA-2026:7876 patch vendor-advisory
- RHSA-2026:7877 patch vendor-advisory
- RHSA-2026:7883 patch vendor-advisory
- RHSA-2026:7833 patch vendor-advisory
- RHSA-2026:7834 patch vendor-advisory
- RHSA-2026:5944 patch vendor-advisory
- RHSA-2026:5942 patch vendor-advisory
- RHSA-2026:7385 patch vendor-advisory
- RHSA-2026:7291 patch vendor-advisory
- RHSA-2026:12282 patch vendor-advisory
- RHSA-2026:14100 patch vendor-advisory
- RHSA-2026:21691 patch vendor-advisory
- RHSA-2026:15091 patch vendor-advisory
- RHSA-2026:14774 patch vendor-advisory
- RHSA-2026:20088 patch vendor-advisory
- RHSA-2026:17598 patch vendor-advisory
- RHSA-2026:12118 patch vendor-advisory
- RHSA-2026:8448 patch vendor-advisory
- RHSA-2026:13736 patch vendor-advisory
- RHSA-2026:4434 patch vendor-advisory
- RHSA-2026:3855 patch vendor-advisory
- RHSA-2026:3559 patch vendor-advisory
- RHSA-2026:3556 patch vendor-advisory
- RHSA-2026:5948 patch vendor-advisory
- RHSA-2026:5950 patch vendor-advisory
- RHSA-2026:5952 patch vendor-advisory
- Ubuntu CVE tracker vendor-advisory
- www.cve.org
- nvd.nist.gov
- security.alpinelinux.org vendor-advisory
- bugs.debian.org issue-tracking
- ENISA EUVD EUVD-2025-206447 third-party-advisory