CVE-2024-56731

Gogs deletion of internal files allows remote command execution

Published Jun 24, 2025 CVSS 3.1 · 10 Critical EPSS 1.1% KEV · Not listed
Description
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.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
EUVD EUVD EUVD-2024-54695 Gogs allows deletion of internal files which leads to remote command execution
Github GHSA Github GHSA GHSA-wj44-9vcg-wjq7 Gogs allows deletion of internal files which leads to remote command execution
History
Type Values Removed Values Added
CPEs cpe:2.3:a:gogs:gogs:*:*:*:*:*:*:*:*
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description 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.
Title Gogs deletion of internal files allows remote command execution
Weaknesses CWE-552
References
Metrics cvssV3_1

{'score': 10, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Jun 25, 2025, 12:43 PM
Reserved
Dec 27, 2024, 3:03 PM
Status
Analyzed
Published
Jun 24, 2025, 4:15 AM
Modified
Jun 17, 2026, 8:12 AM