Maven
CVE-2026-22865
Gradle causes failure to disable repositories exposing builds to malicious artifacts
- Severity
- High
- Published
- 23 Nov 2026
- Last changed
- 23 Nov 2026
- Added to UpHeron
- 23 Nov 2026
- Fixed in
- 8.14.4, 9.3.0
- Exploit chance
- 0.2% in the next 30 daysHigher than 4% of CVEs. EPSS by FIRST, 24 Nov 2026
- Also known as
- BIT-gradle-2026-22865, GHSA-mqwm-5m85-gmcv
- Sources
- OSV.dev and GitHub
Description
When resolving dependencies, Gradle searches repositories in declaration order. If it encounters connection errors, Gradle will disable the repository and fail dependency resolution. This is necessary for both reproducibility and security reasons to prevent dependencies from being resolved from other repositories without warning.
In previous versions of Gradle, some exceptions were not treated as fatal errors and would not cause a repository to be disabled. If a build encountered one of these exceptions, Gradle would continue to the next repository in the list and potentially resolve dependencies from a different repository.
An exception like NoHttpResponseException can indicate transient errors. If the errors persist after a maximum number of retries, Gradle would continue to the next repository.
This behavior could allow an attacker to disrupt the service of a repository and leverage another repository to serve malicious artifacts.
Workarounds
If you are using strict repository content filtering and / or dependency verification, your build is safe from the potential vulnerabilities described above.
If you cannot update to a newer Gradle version, configuring dependency verification is the best way to make sure your build resolves the dependencies you expect and nothing else.
You should also review which repositories your builds use to check for unused or outdated repository declarations.
Affected software
| Software | Affected versions |
|---|---|
org.gradle:gradle-coreMaven · osv:Maven:org.gradle:gradle-core |
|
About org.gradle:gradle-core
Vulnerabilities in org.gradle:gradle-core
- In our list
- 2
- Published in the last 12 months
- 2
- Critical, last 12 months
- 0
- High, last 12 months
- 2
- Known exploited
- 0
- CVE-2026-22816Gradle causes Failure to disable repositories can expose builds to malicious artifactsHigh 23 Nov 2026
References
- CVE.org https://www.cve.org/CVERecord?id=CVE-2026-22865
- GitHub Advisory Database https://github.com/advisories/GHSA-mqwm-5m85-gmcv