CVE-2026-87721: Denial of Service via Exponential Backtracking in ANTLR Search Query Parser in Gerrit Code Review
Vulnerability summary
CVE-2026-87721 is a high (CVSS 8.7) Uncontrolled Resource Consumption vulnerability in gerrit. EPSS estimates a 0.36% chance of exploitation in the next 30 days, higher than 32.3% of scored vulnerabilities.
Severe, CVSS 8.7 (CVE.org); no exploitation reported by the 5 checked sources; EPSS 0% (FIRST, 04-12-2026)
Source freshness unavailable
How is this decided?Timeline
- 24-09-2026PublishedVulnerability first disclosed.
- 25-09-2026Last modifiedVulnerability information updated.
Description
Uncontrolled Resource Consumption (CWE-400 / CWE-407) in the ANTLR 3 search query parser (QueryParser / Query.g) in Gerrit Code Review versions 2.0.19 through 3.12.9, 3.13.0 through 3.13.8, and 3.14.0 through 3.14.2 allows an unauthenticated remote attacker (or an authenticated user if anonymous read access is disabled) to cause a persistent denial of service (CPU exhaustion and HTTP worker thread pool starvation requiring a server restart) via crafted search queries containing deeply nested parentheses sent to query evaluation endpoints (/changes/?q=, /accounts/?q=, /groups/?query=, /projects/?query=, /Documentation/?q=, /changes/{id}/query?expression=, or SSH gerrit query). Because syntactic predicates in conditionOr and conditionAnd recurse via conditionBase without memoization prior to capability or visibility checks and worker threads do not abort when the client disconnects, a small number of requests (such as 25 requests matching default httpd.maxThreads) can permanently pin all HTTP worker threads. This issue is fixed in Gerrit Code Review versions 3.12.10, 3.13.9, and 3.14.3.
CVSS metrics
2 scores · 2 sources · 1 version- NVDNIST8.7HighCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
EPSS trend
Probability
0.36%
Chance of exploitation in the next 30 days
Percentile
32%
Versus all other CVEs
30-day change
Increase +0.04 pp
From 0.32% on 04-11-2026
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root cause- CWE-400Uncontrolled Resource ConsumptionThe product does not properly control the allocation and maintenance of a limited resource.
- CWE-407Inefficient Algorithmic ComplexityAn algorithm in a product has an inefficient worst-case computational complexity that may be detrimental to system performance and can be triggered by an attacker, typically using crafted manipulations that ensure that the worst case is being reached.
- CWE-834Excessive IterationThe product performs an iteration or loop without sufficiently limiting the number of times that the loop is executed.
Affected systems
Known conditions: network-reachable, no authentication, no user interaction (CVSS vector). Other conditions: not stated in public data.
Gerrit1 product
- gerrit≥ 2.0.19, < 3.12.10 | ≥ 3.13.0, < 3.13.9 | ≥ 3.14.0, < 3.14.3
1 vendor · 1 product