CVE-2019-10782
XML external entity (XXE) processing ('external-parameter-entities' feature was not fully disabled))
Description
Due to an incomplete fix for CVE-2019-9658, checkstyle was still vulnerable to XML External Entity (XXE) Processing.
Impact
User: Build Maintainers
This vulnerability probably doesn't impact Maven/Gradle users as, in most cases, these builds are processing files that are trusted, or pre-vetted by a pull request reviewer before being run on internal CI infrastructure.
User: Static Analysis as a Service
If you operate a site/service that parses "untrusted" Checkstyle XML configuration files, you are vulnerable to this and should patch.
Note from the discoverer of the original CVE-2019-9658:
While looking at a few companies that run Checkstyle/PMD/ect... as a service I notice that it's a common pattern to run the static code analysis tool inside of a Docker container with the following flags:
--net=none \ --privileged=false \ --cap-drop=ALLRunning the analysis in Docker has the advantage that there should be no sensitive local file information that XXE can exfiltrate from the container. Additionally, these flags prevent vulnerabilities in static analysis tools like Checkstyle from being used to exfiltrate data via XXE or to perform SSRF. - Jonathan Leitschuh
Patches
Has the problem been patched? What versions should users upgrade to?
Patched, will be released with version 8.29 at 26 Jan 2020.
Workarounds
Is there a way for users to fix or remediate the vulnerability without upgrading?
No workaround are available
References
- CWE-611: Improper Restriction of XML External Entity Reference
- GitHub Issue https://github.com/checkstyle/checkstyle/issues/7468
For more information
If you have any questions or comments about this advisory:
- Open an issue in https://github.com/checkstyle/checkstyle/issues
Affected Maven artifacts (1)
| Artifact | Affected versions | Fixed in |
|---|---|---|
| com.puppycrawl.tools » checkstyle | < 8.29 | 8.29 |
Blast radius
62% of the dependent artifacts (521) still pull an affected version in their latest release.
| Depth | Dependent versions |
|---|---|
| Direct | 2,986 |
| 2 hops | 1,249 |
| 3 hops | 6,214 |
| 4 hops | 4,794 |
| 5 hops | 4,276 |
| 6 hops | 3,763 |
Most used dependents
- org.apache.maven.plugins » maven-checkstyle-plugin11,720 usages
- de.flapdoodle.embed » de.flapdoodle.embed.mongo572 usages
- com.lihaoyi » mill-scalalib320 usages
- com.lihaoyi » mill-main215 usages
- com.powsybl » powsybl-iidm-impl212 usages
- org.openrewrite » rewrite-java207 usages
- guru.nidi » graphviz-java180 usages
- com.powsybl » powsybl-iidm-api137 usages
- org.apache.oozie » oozie-client134 usages
- org.kie.kogito » kogito-quarkus124 usages
- org.apache.oozie » oozie-core123 usages
- org.openrewrite » rewrite-maven110 usages
- org.kie.kogito » kogito-maven-plugin106 usages
- com.powsybl » powsybl-iidm-test85 usages
- com.powsybl » powsybl-ucte-converter84 usages
Computed from the dependency graph of build 20261124.0621 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.
References
| Advisory | NVD CVE-2019-10782 | nvd.nist.gov |
| Web | checkstyle/checkstyle advisory GHSA-763g-fqq7-48wg | github.com |
| Web | checkstyle/checkstyle issue #7468 | github.com |
| Web | checkstyle/checkstyle commit c46a16d | github.com |
| Web | thread.html/r8aaf4ee16bbaf6204731d4770d96ebb34b258cd79b491f9cdd7f2540@<commits.nifi.apache ... | lists.apache.org |
| Web | debian-lts-announce/2020/02/msg00008.html | lists.debian.org |
| Web | vuln/SNYK-JAVA-COMPUPPYCRAWLTOOLS-543266 | snyk.io |
