CVE-2025-64111: Remote Command Execution in Gogs Repository Contents API
- Vendor
- Gogs
CVE-2025-64111 is a critical vulnerability in Gogs, the self-hosted Git service, affecting version 0.13.3 and earlier. The flaw stems from an insufficient fix for CVE-2024-56731 in the repository content update logic. By bypassing security checks in the UpdateRepoFile function, an attacker can use the API to modify files within the repository’s .git directory, including repository configuration data. Abuse of this path validation weakness allows tampering with Git configuration in a way that leads to remote command execution on the Gogs server.
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 result in remote command execution on the server hosting Gogs. An attacker may be able to alter repository configuration to trigger execution of attacker-controlled commands, leading to full compromise of the affected service context. Depending on deployment architecture and privileges, this can enable unauthorized access to repository data, theft of sensitive information, service manipulation, and potential follow-on compromise of adjacent systems reachable from the Gogs host.
Mitigation
If you can’t patch tonight, do this now.
If immediate patching is not possible, restrict or disable the vulnerable repository contents update API functionality, particularly code paths invoking UpdateRepoFile. Enforce server-side validation that rejects writes to any path resolving into the .git directory, including through symlink-based path manipulation. Limit API access to trusted users and networks, reduce repository write permissions where possible, and monitor for suspicious attempts to modify repository configuration through content update operations.
Remediation
Patch, then assume compromise.
Upgrade Gogs to version 0.13.4 or later. The issue is reported as patched in 0.13.4 and 0.14.0+dev. Because the vulnerability is due to an incomplete prior fix, administrators should ensure all affected instances are updated to a release that fully blocks writes resolving into the .git directory through the repository contents API.
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-64111 exploited in the wild?
- As of Sep 25, 2026, Mallory has no reports of CVE-2025-64111 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2025-64111?
- Yes. As of Sep 25, 2026, Mallory has reports of a public exploit for CVE-2025-64111.
- Is there a patch for CVE-2025-64111?
- Upgrade Gogs to version 0.13.4 or later. The issue is reported as patched in 0.13.4 and 0.14.0+dev.
- What products are affected by CVE-2025-64111?
- Gogs.
- How severe is CVE-2025-64111?
- CVE-2025-64111 has a CVSS v4 score of 9.3 (Critical) and an EPSS score of 1.4% (73rd percentile) as of Sep 25, 2026.
Recent activity
6 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.