CVE-2023-6840
GitLab vulnerability analysis and mitigation

Overview

An issue has been discovered in GitLab Enterprise Edition (EE) affecting all versions from 16.4 prior to 16.6.7, 16.7 prior to 16.7.5, and 16.8 prior to 16.8.2 which allows a maintainer to change the name of a protected branch that bypasses the security policy added to block MR (GitLab Security, NVD).

Technical details

The vulnerability allows project maintainers to bypass group's scan result policy block_branch_modification setting. When this setting is enabled, it should prevent users from removing a branch from the protected branches list, deleting a protected branch, or changing the default branch if that branch is included in the security policy. However, maintainers can bypass this protection by sending an API request to update the protected branch name, effectively removing the protection status (GitLab Issue). The vulnerability has been assigned a CVSS v3.1 base score of 6.7 (Medium) with vector: AV:N/AC:L/PR:H/UI:N/S:U/C:L/I:H/A:H (NVD).

Impact

The vulnerability allows maintainers to bypass security policies and remove protection status from branches, potentially enabling the merging of vulnerable code. This undermines the security controls put in place by group owners to prevent unauthorized modifications to protected branches (GitLab Issue).

Mitigation and workarounds

The vulnerability has been fixed in GitLab versions 16.6.7, 16.7.5, and 16.8.2. Users are strongly recommended to upgrade to these patched versions immediately. The fix prevents the modification of protected branch names when the block_branch_modification setting is enabled (GitLab Security).

Additional resources


SourceThis report was generated using AI

Related GitLab vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-9222HIGH8.7
  • GitLabGitLab
  • cpe:2.3:a:gitlab:gitlab
NoYesJan 09, 2026
CVE-2025-11224HIGH7.7
  • GitLabGitLab
  • cpe:2.3:a:gitlab:gitlab
NoYesJan 14, 2026
CVE-2025-13772HIGH7.1
  • GitLabGitLab
  • cpe:2.3:a:gitlab:gitlab
NoYesJan 09, 2026
CVE-2025-13781MEDIUM6.5
  • GitLabGitLab
  • cpe:2.3:a:gitlab:gitlab
NoYesJan 09, 2026
CVE-2025-3950LOW3.5
  • GitLabGitLab
  • cpe:2.3:a:gitlab:gitlab
NoYesJan 09, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management