Summary
Gradle causes failure to disable repositories exposing builds to malicious artifacts
Vulnerability caused by continuing after max retries on transient errors
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. This attack requires the attacker to have control over a repository after the disrupted repository.
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.
Related
Impact
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.
Affected versions
Security releases
Kodem intelligence
Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.
Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.
Already deployed Kodem?
See it in your environmentNew to Kodem? Get a demo →Remediation advice
Gradle has introduced a change in behavior in Gradle 9.3.0 and 8.14.4 to stop searching other repositories when encountering these errors.
Upgrading to either version will protect you against the vulnerabilities described here.
Frequently Asked Questions
- What is CVE-2026-22865? CVE-2026-22865 is a high-severity security vulnerability in org.gradle:gradle-core (maven), affecting versions < 8.14.4. It is fixed in 8.14.4, 9.3.0.
- Which versions of org.gradle:gradle-core are affected by CVE-2026-22865? org.gradle:gradle-core (maven) versions < 8.14.4 is affected.
- Is there a fix for CVE-2026-22865? Yes. CVE-2026-22865 is fixed in 8.14.4, 9.3.0. Upgrade to this version or later.
- Is CVE-2026-22865 exploitable, and should I be worried? Whether CVE-2026-22865 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
- What actually determines whether CVE-2026-22865 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
- How do I fix CVE-2026-22865?
- Upgrade
org.gradle:gradle-coreto 8.14.4 or later - Upgrade
org.gradle:gradle-coreto 9.3.0 or later
- Upgrade