CVE-2025-5101: Improper Control of Generation of Code ('Code Injection') in GitLab
An issue has been discovered in GitLab CE/EE affecting all versions before 18.1.5, 18.2 before 18.2.5, and 18.3 before 18.3.1 that under certain conditions could have allowed an authenticated attacker to distribute malicious code that appears harmless in the web interface by taking advantage of ambiguity between branches and tags during repository imports.
Other sources
GitLab has remediated an issue that under certain conditions could have allowed an authenticated attacker to distribute malicious code that appears harmless in the web interface by taking advantage of ambiguity between branches and tags during repository imports.
— GitLab
Affected Software
Remediation
Information
Event History
Peer vulnerabilities
Found alongside the following vulnerabilities.
Frequently Asked Questions
What is the severity of CVE-2025-5101?
CVE-2025-5101 has been rated as a moderate severity vulnerability due to its potential to allow authenticated attackers to execute harmful code.
How do I fix CVE-2025-5101?
To fix CVE-2025-5101, upgrade your GitLab installation to version 18.1.5 or later, 18.2.5 or later, or 18.3.1 or later.
Who is affected by CVE-2025-5101?
CVE-2025-5101 affects all versions of GitLab CE/EE before 18.1.5, 18.2 before 18.2.5, and 18.3 before 18.3.1.
What types of attacks are possible with CVE-2025-5101?
CVE-2025-5101 could allow authenticated attackers to distribute malicious code that may appear harmless through the web interface.
How can I determine if I am running a vulnerable version related to CVE-2025-5101?
Check your GitLab version against the versions listed for CVE-2025-5101 to determine if you are vulnerable.