CVE-2025-68119: Go Toolchain VCS Argument Injection Leading to Code Execution or Arbitrary File Writes
- Vendor
- Golang
CVE-2025-68119 is an argument-injection vulnerability in the Go toolchain's construction of external version-control commands during module retrieval and builds. On systems with Mercurial installed, retrieving modules from non-standard sources, such as custom domains, can cause arbitrary local code execution. Supplying a malicious module version string can also trigger the Mercurial issue. On systems with Git installed, explicitly supplied malicious module version strings can cause arbitrary file writes. The Git-related attack does not affect module resolution using @latest or bare module paths. Fixes use safer version-control options and reject module version strings beginning with a hyphen or forward slash.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Successful exploitation can execute attacker-controlled code with the permissions of the account running the Go toolchain or overwrite arbitrary files writable by that account. Developer workstations and automated build environments processing attacker-controlled module sources or versions are at risk. Consequences can include compromise of accessible data, modification of build inputs or outputs, and disruption of the build environment.
Mitigation
If you can’t patch tonight, do this now.
Until patched, avoid retrieving modules from untrusted non-standard sources and prevent attacker-controlled version strings from reaching the Go toolchain. Validate module source and version inputs in build pipelines, including rejecting version strings beginning with '-' or '/'. Using @latest or bare module paths avoids the explicitly supplied malicious-version-string attack affecting Git, but does not establish protection against the Mercurial custom-source attack.
Remediation
Patch, then assume compromise.
Upgrade the Go toolchain to Go 1.24.12 or Go 1.25.6, or a later supported release containing the fixes. Update affected distribution-provided Go packages using the corresponding security updates. Ensure developer environments and CI build images use the corrected toolchain. The patch hardens external VCS invocation and rejects module version strings beginning with '-' or '/'.
Exploits
No public exploits tracked yet. Mallory keeps watching.
Affected products & vendors
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
Frequently asked questions
- Is CVE-2025-68119 exploited in the wild?
- As of Nov 23, 2026, Mallory has no reports of CVE-2025-68119 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2025-68119?
- As of Nov 23, 2026, Mallory has found no public exploit for CVE-2025-68119.
- Is there a patch for CVE-2025-68119?
- Upgrade the Go toolchain to Go 1.24.12 or Go 1.25.6, or a later supported release containing the fixes. Update affected distribution-provided Go packages using the corresponding security updates.
- What products are affected by CVE-2025-68119?
- Golang Go.
- How severe is CVE-2025-68119?
- CVE-2025-68119 has a CVSS v3.1 score of 7.0 (High) and an EPSS score of 0.29% (14th percentile) as of Nov 23, 2026.
Recent activity
27 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.