GitLabApplication

CVE-2024-4597

MEDIUM · 6.5 CVSS v3.1 Published 2024-05-14
Fix available
A fix is available. Upgrade to 16.9.7 / 16.10.5 or later.
See remediation →
72/100
Remediation priority · Elevated
Remotely reachable No privileges

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
An issue has been discovered in GitLab EE affecting all versions from 16.7 before 16.9.7, all versions starting from 16.10 before 16.10.5, all versions starting from 16.11 before 16.11.2. An attacker could force a user with an active SAML session to approve an MR via CSRF.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

A CSRF vulnerability in GitLab EE allows attackers to force users with active SAML sessions to approve merge requests without consent. The MR approval endpoint lacks proper CSRF token validation, enabling malicious forged requests when a victim visits an attacker-controlled page while authenticated.

MitigationUpgrade to GitLab versions 16.9.7, 16.10.5, 16.11.2 or later. Ensure CSRF protection is enabled and functional for all state-changing operations, particularly merge request approvals.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
GitLabApplication
Affected:>= 16.7.0, < 16.9.7>= 16.10.0, < 16.10.5>= 16.11.0, < 16.11.2

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
Required
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
None

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:N

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Identify installed GitLab version
    Run `gitlab-rake gitlab:version` or check the version file at `/opt/gitlab/VERSION` (path may vary based on installation method)
    Affected if The version falls within >= 16.7.0 and < 16.9.7, OR >= 16.10.0 and < 16.10.5, OR >= 16.11.0 and < 16.11.2
  2. Verify SAML authentication is configured
    Check GitLab admin settings at Admin Area > Authentication > SAML or inspect the gitlab.rb configuration file for `gitlab_rails['omniauth_enabled']` with SAML provider settings
    Affected if SAML single sign-on is enabled and users authenticate via SAML
  3. Confirm merge request approval functionality is accessible
    Navigate to a project's merge requests settings or check via API at /projects/:id/approvals to verify approval rules are configured and available
    Affected if Merge request approvals feature is enabled for any project
  4. Inspect CSRF protection status
    Check gitlab.rb for `gitlab_rails['csrf_protection_enabled'] = true` or verify in Rails configuration that forgery protection is active
    Affected if CSRF protection is disabled or may not be properly validating the approval endpoint

You are affected if your GitLab version is within the affected ranges AND SAML authentication is enabled AND merge request approvals are in use, as the CSRF token validation can be bypassed for the approval endpoint.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to 16.9.7 / 16.10.5 / 16.11.2 or later
Fixed in 16.9.716.10.516.11.2
Interim mitigation

Upgrade to GitLab versions 16.9.7, 16.10.5, 16.11.2 or later. Ensure CSRF protection is enabled and functional for all state-changing operations, particularly merge request approvals.

Recommended fix High confidence

16.9.7 (or 16.10.5 or 16.11.2 depending on your release line)

  1. Identify current GitLab version via admin area or `sudo gitlab-rake gitlab:version`
  2. Plan upgrade to the next fixed version within your release line: if on 16.7.x-16.9.x upgrade to 16.9.7; if on 16.10.x upgrade to 16.10.5; if on 16.11.x-16.11.y upgrade to 16.11.2
  3. Review GitLab upgrade documentation for your migration path
  4. Execute upgrade following standard GitLab upgrade procedures
  5. After upgrade, verify the new version is running and SAML merge request approval functionality works as expected
Caveat Review GitLab release notes for any breaking changes between your current and target version; minor version upgrades within same major line typically have minimal breaking changes

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in GitLab Scoped from the published advisory
  • Consultation2.0 h
  • Implementation8.0 h
  • Testing4.0 h
  • Review / QA2.0 h
16.0 hours of engineering $2,800
Get the upgrade done

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $4,480.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2024-4597 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2024-4597 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data