Vulnerabilities / CVE-2024-39930

critical

CVE-2024-39930

Gogs has an argument Injection in the built-in SSH server

Published Modified CWE 88
In the Trivy database since at least 24 Oct 2026, 07:11 UTCWhen it arrived before that build is not recorded.

Severity by source

NVD9.9CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
GHSA10.0CVSS:3.1/AC:L/AV:N/A:H/C:H/I:H/PR:L/S:C/UI:N

Trivy's own label is CRITICAL. Rated critical by NVD, GHSA.

Description

The built-in SSH server of Gogs through 0.13.0 allows argument injection in internal/ssh/ssh.go, leading to remote code execution. Authenticated attackers can exploit this by opening an SSH connection and sending a malicious --split-string env request if the built-in SSH server is activated. Windows installations are unaffected.

Affected packages and fixed versions

SourcePackageFixed in
go::GitHub Security Advisory Gogogs.io/gogs0.13.1
rapidfort alpine 3.20gogsno fix listed
rapidfort alpine 3.21gogsno fix listed
rapidfort alpine 3.22gogsno fix listed
rapidfort alpine 3.23gogsno fix listed
rapidfort alpine 3.24gogsno fix listed

References

Vulnerability data compiled from the Trivy vulnerability database (trivy-db, Aqua Security, Apache License 2.0), which aggregates third-party advisories. CVE records are published by The MITRE Corporation under the CVE Terms of Use; CVE is a trademark of MITRE. This product uses data from the NVD API but is not endorsed or certified by the NVD. Severity, titles and advisory data from the GitHub Advisory Database (CC BY 4.0), Red Hat security data (CC BY 4.0) and the other sources linked on each entry. Entries may be summarised or re-formatted; the linked original is the authoritative record.