CVE-2021-22175

GitLab SSRF Exploitation (CVE-2021-22175)

Detects exploitation of CVE-2021-22175, a Server-Side Request Forgery (SSRF) vulnerability in GitLab. An attacker can craft requests that cause the GitLab server to make HTTP requests to internal or external resources, potentially exposing cloud metadata endpoints, internal services, or facilitating lateral movement. This vulnerability is listed in CISA's Known Exploited Vulnerabilities catalog.

Vulnerability Intelligence

KEV — Known Exploited

Affected Software

Vendor
GitLab
Product
GitLab

Weakness (CWE)

Timeline

Disclosed
February 18, 2026

CVSS

Unscored
Write-up coming soon

What is CVE-2021-22175 GitLab SSRF Exploitation (CVE-2021-22175)?

GitLab SSRF Exploitation (CVE-2021-22175) (CVE-2021-22175) maps to the Reconnaissance and Discovery and Lateral Movement tactics — the adversary is trying to gather information they can use to plan future operations in MITRE ATT&CK.

This page provides production-ready detection logic for GitLab SSRF Exploitation (CVE-2021-22175), covering the data sources and telemetry it touches: Azure Application Gateway, Common Security Log, IIS Logs, GitLab Access Logs. The queries below are rated high severity at medium confidence, and ship for 7 SIEM platforms — KQL, SPL, Elastic, QRadar, Sumo, YARA-L, LogScale.

MITRE ATT&CK

Tactic
Reconnaissance Discovery Lateral Movement
Microsoft Sentinel / Defender
kusto
union isfuzzy=true
(
    AzureDiagnostics
    | where Category == "ApplicationGatewayAccessLog"
    | where requestUri_s matches regex @"/(import|export|hook|webhook|integrations|api/v4/projects/[0-9]+/import)"
    | where httpStatus_i in (200, 302, 400, 500)
    | extend TargetUrl = tostring(parse_url(requestUri_s))
    | where requestUri_s contains "url=" or requestUri_s contains "remote=" or requestUri_s contains "import_url"
),
(
    CommonSecurityLog
    | where DeviceVendor == "GitLab" or ApplicationProtocol == "HTTP"
    | where RequestURL matches regex @"/(import|hook|webhook|integrations)"
    | where RequestURL contains "169.254.169.254" or RequestURL contains "metadata" or RequestURL contains "internal"
    | extend SSRFIndicator = true
),
(
    W3CIISLog
    | where csUriStem matches regex @"/(import|hook|webhook)"
    | where csUriQuery contains "url=http" or csUriQuery contains "url=https"
    | extend DecodedQuery = url_decode(csUriQuery)
    | where DecodedQuery contains "169.254" or DecodedQuery contains "10." or DecodedQuery contains "192.168." or DecodedQuery contains "localhost"
)
| summarize RequestCount=count(), FirstSeen=min(TimeGenerated), LastSeen=max(TimeGenerated) by SourceIP=coalesce(clientIp_s, SourceIP, cIP), TargetEndpoint=coalesce(requestUri_s, RequestURL, csUriStem)
| where RequestCount >= 1
| extend Severity = "High", CVE = "CVE-2021-22175"
| order by RequestCount desc

Detects HTTP requests to GitLab endpoints commonly targeted in SSRF exploitation (import, webhook, integrations) that contain internal IP addresses, cloud metadata endpoints, or SSRF-indicative URL parameters.

high severity medium confidence

Data Sources

Azure Application Gateway Common Security Log IIS Logs GitLab Access Logs

Required Tables

AzureDiagnostics CommonSecurityLog W3CIISLog

False Positives

  • Legitimate GitLab project imports from external repositories using HTTP/HTTPS URLs
  • Webhook configuration testing by developers pointing to internal test environments
  • Security scanners or vulnerability assessment tools probing GitLab endpoints
  • GitLab CI/CD pipelines that legitimately reference internal service URLs

Sigma rule & cross-platform mapping

The detection logic for GitLab SSRF Exploitation (CVE-2021-22175) (CVE-2021-22175) above is provided in a vendor-neutral form so you can deploy it on any SIEM. The same logic is shipped here as native KQL (Microsoft Sentinel / Defender), SPL (Splunk), Elastic (Elastic Security (EQL)), QRadar (IBM QRadar (AQL)), Sumo (Sumo Logic CSE), YARA-L (Google Chronicle / SecOps), LogScale (CrowdStrike LogScale (CQL)) queries. In Sigma terms, this detection targets the following logsource:

logsource:
  product: azure

Browse the community-maintained Sigma rules for this technique:


Testing Methodology

Validate this detection against 3 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.

  1. Test 1GitLab SSRF via Project Import URL - AWS Metadata

    Expected signal: Outbound HTTP GET to 169.254.169.254 from GitLab server process; network flow record showing connection to 169.254.0.0/16 from GitLab host; GitLab production.log entry with import_url containing metadata endpoint

  2. Test 2GitLab SSRF via Webhook Creation - Internal Service Probe

    Expected signal: Network connection from GitLab server to 192.168.1.1:8500 visible in network flow data; GitLab web_hooks table entry with internal IP URL; web server access log showing webhook API POST with internal URL in body

  3. Test 3GitLab SSRF via Remote Mirror - Loopback File Access

    Expected signal: GitLab application log entries showing file:// or gopher:// scheme in remote mirror URL; database record in remote_mirrors table with dangerous URL scheme; error log entries from GitLab attempting to process the invalid/dangerous URL

Unlock Pro Content

Get the full detection package for CVE-2021-22175 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections