Skip to main content
CVE Vulnerability Database

CVE-2025-2246: GitLab Information Disclosure Vulnerability

CVE-2025-2246 is an information disclosure flaw in GitLab CE/EE that allows unauthenticated users to access sensitive CI/CD variables via GraphQL API. This article covers technical details, affected versions, and mitigation.

Published:

CVE-2025-2246 Overview

CVE-2025-2246 is an authorization flaw in GitLab Community Edition (CE) and Enterprise Edition (EE) that exposes sensitive manual CI/CD variables to unauthenticated attackers through the GraphQL API. The vulnerability affects all GitLab versions before 18.1.5, versions 18.2 before 18.2.5, and versions 18.3 before 18.3.1. An unauthenticated attacker can query the GraphQL endpoint to retrieve manual variables that projects use for pipeline execution. These variables commonly contain secrets such as API tokens, deployment credentials, and environment configuration. The weakness is classified as Missing Authorization [CWE-862].

Critical Impact

Unauthenticated remote attackers can read sensitive CI/CD variables, potentially exposing secrets used by build pipelines, deployment jobs, and integrated third-party services.

Affected Products

  • GitLab CE/EE all versions before 18.1.5
  • GitLab CE/EE 18.2 before 18.2.5
  • GitLab CE/EE 18.3 before 18.3.1

Discovery Timeline

  • 2025-08-27 - CVE-2025-2246 published to NVD
  • 2026-06-17 - Last updated in NVD database

Technical Details for CVE-2025-2246

Vulnerability Analysis

The vulnerability resides in GitLab's GraphQL API, which lacks proper authorization checks when returning manual CI/CD variable data. Manual variables are values developers configure on a pipeline or job and typically hold sensitive material such as deployment keys and access tokens. GitLab expects only authorized project members to read these values. Because the GraphQL resolver did not enforce the required permission check, requests without authentication returned the variable data. This exposure enables reconnaissance against internet-reachable GitLab instances and supports supply chain attacks against downstream systems that trust those secrets.

Root Cause

The root cause is a Missing Authorization defect [CWE-862] in a GraphQL query resolver. The resolver returned manual CI/CD variable objects without verifying that the caller had permission to access the parent project or pipeline. Authorization policies applied elsewhere in the REST API and web interface were not consistently applied to this GraphQL path.

Attack Vector

Exploitation requires only network access to a vulnerable GitLab instance. An attacker sends a crafted GraphQL query to the public endpoint with no credentials or session token. The response includes manual variables that should be restricted to project members. No user interaction is required, and the attack leaves standard web request traces. Refer to the GitLab Issue Report and the HackerOne Security Report #3026559 for technical details.

Detection Methods for CVE-2025-2246

Indicators of Compromise

  • Unauthenticated POST requests to /api/graphql originating from unexpected IP ranges or automated clients.
  • GraphQL queries that reference ciVariables, manualVariables, or pipeline variable fields without a valid PRIVATE-TOKEN or session cookie.
  • Sudden spikes in GraphQL query volume against project or pipeline objects.

Detection Strategies

  • Enable GitLab's GraphQL query logging and review requests that return variable data without an authenticated user.
  • Correlate web server access logs against authentication logs to isolate anonymous GraphQL traffic touching CI/CD resources.
  • Rotate and monitor CI/CD secrets referenced by manual variables to detect downstream misuse.

Monitoring Recommendations

  • Alert on any HTTP 200 response to /api/graphql where the request lacks an authentication header and the query body contains variable-related field names.
  • Track outbound activity from services whose credentials were stored as manual CI/CD variables, watching for anomalous logins or API calls.
  • Baseline normal GraphQL traffic per source IP and flag deviations that could indicate scraping.

How to Mitigate CVE-2025-2246

Immediate Actions Required

  • Upgrade GitLab CE/EE to 18.1.5, 18.2.5, 18.3.1, or later without delay.
  • Rotate all manual CI/CD variables on affected projects, including tokens, deployment keys, and third-party API credentials.
  • Audit GraphQL access logs for the exposure window and identify any variables that may have been read by unauthenticated clients.

Patch Information

GitLab released fixed versions 18.1.5, 18.2.5, and 18.3.1 that enforce authorization on the affected GraphQL resolvers. Administrators running self-managed GitLab should apply these updates immediately. GitLab.com SaaS customers receive the fix automatically. Details are tracked in the GitLab Issue Report.

Workarounds

  • Restrict network access to the GitLab GraphQL endpoint using a reverse proxy or firewall until patches are deployed.
  • Require authentication at the load balancer layer for /api/graphql requests where feasible.
  • Move highly sensitive secrets from manual CI/CD variables into an external secrets manager referenced at runtime.
bash
# Example: block unauthenticated GraphQL requests at an NGINX reverse proxy
location /api/graphql {
    if ($http_authorization = "") {
        return 401;
    }
    proxy_pass http://gitlab_upstream;
}

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.