CVE-2024-56731
CRITICAL 9.8CVSS 3.1Gogs allows deletion of internal files which leads to remote command execution
Gogs is an open source self-hosted Git service. Prior to version 0.13.3, it's still possible to delete files under the .git directory and achieve remote command execution due to an insufficient patch for CVE-2024-39931. Unprivileged user accounts can execute arbitrary commands on the Gogs instance with the privileges of the account specified by RUN_USER in the configuration. Allowing attackers to access and alter any users' code hosted on the same instance. This issue has been patched in version 0.13.3.
- Published
- 24 Jun 2025
- Last modified
- 17 Jun 2026
- Assigned by
- security-advisories@github.com
- NVD status
- Analyzed
- Weakness
- CWE-552
- Also known as
- GHSA-wj44-9vcg-wjq7GO-2025-3776
- Sources
- NVDJSONOSV GHSA-wj44-9vcg-wjq7JSONOSV GO-2025-3776JSON
Scores
| Source | Scored by | Version | Score | Vector / decision |
|---|---|---|---|---|
| NVD | security-advisories@github.com (Secondary) | CVSS 3.1 | CRITICAL 10.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H |
| OSV | GitHub | CVSS 3.1 | CRITICAL 10.0 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H |
| NVD | nvd@nist.gov (Primary) | CVSS 3.1 | CRITICAL 9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| NVD | gogs | gogscpe:2.3:a:gogs:gogs:*:*:*:*:*:*:*:* |
< 0.13.3 | 0.13.3 |
| OSV | Go | gogs.io/gogs | < 0.13.3 | 0.13.3 |
References
- https://github.com/gogs/gogs/commit/77a4a945ae9a87f77e392e9066b560edb71b5de9 · Patch, WEB
- https://github.com/gogs/gogs/releases/tag/v0.13.3 · Release Notes, WEB
- https://github.com/gogs/gogs/security/advisories/GHSA-wj44-9vcg-wjq7 · Patch, Vendor Advisory, WEB, ADVISORY
- https://nvd.nist.gov/vuln/detail/CVE-2024-56731 · ADVISORY
- https://github.com/advisories/GHSA-ccqv-43vm-4f3w · ADVISORY, WEB
- https://github.com/gogs/gogs · PACKAGE
History
- 25 Nov 2026 20:58 UTC · NVD: first stored (published 24 Jun 2025)
- 25 Nov 2026 20:14 UTC · OSV: first stored (published 28 Jul 2025)
- 25 Nov 2026 20:14 UTC · OSV: first stored (published 24 Jun 2025)