Advisory

GHSA-ccqv-43vm-4f3w

Also known as: CVE-2024-39931, GHSA-2vgj-3pvg-xh4w, GO-2024-2970

Summary

Gogs allows deletion of internal files

Details

Impact

Unprivileged user accounts can execute arbitrary commands on the Gogs instance with the privileges of the account specified by RUN_USER in the configuration. It allows attackers to access and alter any users' code hosted on the same instance.

Patches

Deletion of .git files has been prohibited (https://github.com/gogs/gogs/pull/7870). Users should upgrade to 0.13.1 or the latest 0.14.0+dev.

Workarounds

No viable workaround available, please only grant access to trusted users to your Gogs instance on affected versions.

References

https://www.cve.org/CVERecord?id=CVE-2024-39931

Severity

Critical Basis: The source's own band: CRITICAL

Dates

Published
2024-12-23 20:38 UTC
Modified
2024-12-23 20:56 UTC

Affected packages and fixes

gogs.io/gogs

Go · All systems

Affected

  • introduced 0, fixed 0.13.1 (semver)

Fixed versions

0.13.1

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences