Vulnerabilities in pkg:maven/io.github.1tchy.java9modular.org.apache.commons/commons-compress

PACKAGE
Advisory Identifier: GHSA-53x6-4x5p-rrvv
Advisory Summary

CVE-2019-12402 is a HIGH (CVSS 7.5) denial of service vulnerability (CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop')) affecting Commons compress libraries in the Maven ecosystem. The issue involves denial of service in apache commons compress. Remediation is available by upgrading affected packages to version 1.19.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:maven/io.github.1tchy.java9modular.org.apache.commons/commons-compress

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:maven/io.github.1tchy.java9modular.org.apache.commons/commons-compress. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-53x6-4x5p-rrvv CVE-2019-12402 HIGH Denial of Service in Apache Commons Compress

CVE-2019-12402 at a Glance

CVE Identifier CVE-2019-12402
GHSA Identifier GHSA-53x6-4x5p-rrvv
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop')
Affected Product Commons compress
Package Ecosystem Maven
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity None (I:N)
Availability High (A:H)

How to Fix CVE-2019-12402

To remediate this vulnerability, upgrade all affected Commons compress dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

org.apache.commons:commons-compress fixed: 1.19
<dependency>
    <groupId>org.apache.commons</groupId>
    <artifactId>commons-compress</artifactId>
    <version>1.19</version>
</dependency>
io.github.1tchy.java9modular.org.apache.commons:commons-compress fixed: Latest secure release
<dependency>
    <groupId>io.github.1tchy.java9modular.org.apache.commons</groupId>
    <artifactId>commons-compress</artifactId>
    <version>Latest secure release</version>
</dependency>
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

mvn dependency:tree -Dincludes=org.apache.commons

How to Check if You Are Affected

To determine whether your Java application is affected by CVE-2019-12402, inspect your build dependencies using the Maven Dependency Plugin:

mvn dependency:tree -Dincludes=org.apache.commons

Analyze the terminal output to locate any version of Commons compress in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.19), your application is affected.

Note: The mvn dependency:tree -Dincludes=org.apache.commons command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop'), where the product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop. In Commons compress, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

The file name encoding algorithm used internally in Apache Commons Compress 1.15 to 1.18 can get into an infinite loop when faced with specially crafted inputs. This can lead to a denial of service attack if an attacker can choose the file names inside of an archive created by Compress.

CVE-2019-12402 Affected Commons compress Versions

2 component(s)
Fixed Versions:
1.19
Product / Package Ecosystem Affected Versions Fixed Version
org.apache.commons:commons-compress
Maven
≥ 1.15
< 1.19
1.19
io.github.1tchy.java9modular.org.apache.commons:commons-compress
Maven
1.18.1
All 1 versions
1.18.1
None specified

References

NVD — CVE-2019-12402 NVD
https://nvd.nist.gov/vuln/detail/CVE-2019-12402
Commons compress Security Information SECURITY
https://www.oracle.com/security-alerts/cpuoct2021.html
Commons compress Security Information SECURITY
https://www.oracle.com/security-alerts/cpuoct2020.html
Commons compress Security Information SECURITY
https://www.oracle.com/security-alerts/cpujul2020.html
Commons compress Security Information SECURITY
https://www.oracle.com/security-alerts/cpujan2021.html
Commons compress Security Information SECURITY
https://www.oracle.com/security-alerts/cpuapr2022.html
Commons compress Security Information SECURITY
https://www.oracle.com/security-alerts/cpuapr2020.html
Commons compress Security Information SECURITY
https://www.oracle.com/security-alerts/cpuApr2021.html
Commons compress Security Information SECURITY
https://www.oracle.com//security-alerts/cpujul2021.html
Commons compress Security Information SECURITY
https://security.netapp.com/advisory/ntap-20230818-0001
lists.fedoraproject.org/archives/list/packa... WEB
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/WZB3GB7YXIOUKIOQ27VTIP6KKGJJ3CKL
lists.fedoraproject.org/archives/list/packa... WEB
https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/QLJIK2AUOZOWXR3S5XXBUNMOF3RTHTI7
lists.apache.org/thread.html/rf5230a... WEB
https://lists.apache.org/thread.html/rf5230a049d989dbfdd404b4320a265dceeeba459a4d04ec21873bd55@%3Csolr-user.lucene.apache.org%3E
lists.apache.org/thread.html/re13bd2... WEB
https://lists.apache.org/thread.html/re13bd219dd4b651134f6357f12bd07a0344eea7518c577bbdd185265@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/rdebc18... WEB
https://lists.apache.org/thread.html/rdebc1830d6c09c11d5a4804ca26769dbd292d17d361c61dea50915f0@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/rd3f99d... WEB
https://lists.apache.org/thread.html/rd3f99d732baed459b425fb0a9e9e14f7843c9459b12037e4a9d753b5@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/rcc35ab... WEB
https://lists.apache.org/thread.html/rcc35ab6be300365de5ff9587e0479d10d7d7c79070921837e3693162@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r972f82... WEB
https://lists.apache.org/thread.html/r972f82d821b805d04602976a9736c01b6bf218cfe0c3f48b472db488@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r7af60f... WEB
https://lists.apache.org/thread.html/r7af60fbd8b2350d49d14e53a3ab2801998b9d1af2d6fcac60b060a53@%3Cdev.brooklyn.apache.org%3E
lists.apache.org/thread.html/r5caf4f... WEB
https://lists.apache.org/thread.html/r5caf4fcb69d2749225391e61db7216282955204849ba94f83afe011f@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r590c15... WEB
https://lists.apache.org/thread.html/r590c15cebee9b8e757e2f738127a9a71e48ede647a3044c504e050a4@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r5103b1... WEB
https://lists.apache.org/thread.html/r5103b1c9242c0f812ac96e524344144402cbff9b6e078d1557bc7b1e@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r4363c9... WEB
https://lists.apache.org/thread.html/r4363c994c8bca033569a98da9218cc0c62bb695c1e47a98e5084e5a0@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r25422d... WEB
https://lists.apache.org/thread.html/r25422df9ad22fec56d9eeca3ab8bd6d66365e9f6bfe311b64730edf5@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r233267... WEB
https://lists.apache.org/thread.html/r233267e24519bacd0f9fb9f61a1287cb9f4bcb6e75d83f34f405c521@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r21d647... WEB
https://lists.apache.org/thread.html/r21d64797914001119d2fc766b88c6da181dc2308d20f14e7a7f46117@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/r204ba2... WEB
https://lists.apache.org/thread.html/r204ba2a9ea750f38d789d2bb429cc0925ad6133deea7cbc3001d96b5@%3Csolr-user.lucene.apache.org%3E
lists.apache.org/thread.html/r05cf37... WEB
https://lists.apache.org/thread.html/r05cf37c1e1e662e968cfece1102fcd50fe207181fdbf2c30aadfafd3@%3Cissues.flink.apache.org%3E
lists.apache.org/thread.html/9317fd0... WEB
https://lists.apache.org/thread.html/9317fd092b257a0815434b116a8af8daea6e920b6673f4fd5583d5fe@%3Ccommits.druid.apache.org%3E
lists.apache.org/thread.html/54cc4e9... WEB
https://lists.apache.org/thread.html/54cc4e9fa6b24520135f6fa4724dfb3465bc14703c7dc7e52353a0ea@%3Ccommits.creadur.apache.org%3E
lists.apache.org/thread.html/308cc15... WEB
https://lists.apache.org/thread.html/308cc15f1f1dc53e97046fddbac240e6cd16de89a2746cf257be7f5b@%3Cdev.commons.apache.org%3E
Commons compress Source Repository REPOSITORY
https://github.com/jensdietrich/xshady-release/tree/main/CVE-2019-12402

Frequently Asked Questions

What is CVE-2019-12402?
CVE-2019-12402 is a security vulnerability in Commons compress involving Denial of Service in Apache Commons Compress under CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop').
Which Commons compress versions are affected?
Affected versions include releases prior to 1.19 across affected packages: org.apache.commons:commons-compress, io.github.1tchy.java9modular.org.apache.commons:commons-compress.
What version fixes CVE-2019-12402?
Upgrading to 1.19 (or the latest patched release for your respective branch) resolves the vulnerability.
Is commons-compress affected?
Yes, org.apache.commons:commons-compress is affected in releases prior to 1.19, Latest secure release. Upgrade your dependency to 1.19, Latest secure release or later.
What is the CVSS score of CVE-2019-12402?
CVE-2019-12402 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
What CWE is associated with CVE-2019-12402?
CVE-2019-12402 is classified under CWE-835: Loop with Unreachable Exit Condition ('Infinite Loop') (The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop.).
How can I check Maven dependencies for CVE-2019-12402?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=org.apache.commons'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-53x6-4x5p-rrvv",
  "modified" : "2021-06-15T17:21:48Z",
  "published" : "2019-10-11T18:41:08Z",
  "aliases" : [ "CVE-2019-12402" ],
  "summary" : "Denial of Service in Apache Commons Compress",
  "details" : "The file name encoding algorithm used internally in Apache Commons Compress 1.15 to 1.18 can get into an infinite loop when faced with specially crafted inputs. This can lead to a denial of service attack if an attacker can choose the file names inside of an archive created by Compress.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.commons:commons-compress"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.15"
      }, {
        "fixed" : "1.19"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "io.github.1tchy.java9modular.org.apache.commons:commons-compress"
    },
    "versions" : [ "1.18.1" ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2019-12402"
  }, {
    "type" : "WEB",
    "url" : "https://www.oracle.com/security-alerts/cpuoct2021.html"
  }, {
    "type" : "WEB",
    "url" : "https://www.oracle.com/security-alerts/cpuoct2020.html"
  }, {
    "type" : "WEB",
    "url" : "https://www.oracle.com/security-alerts/cpujul2020.html"
  }, {
    "type" : "WEB",
    "url" : "https://www.oracle.com/security-alerts/cpujan2021.html"
  }, {
    "type" : "WEB",
    "url" : "https://www.oracle.com/security-alerts/cpuapr2022.html"
  }, {
    "type" : "WEB",
    "url" : "https://www.oracle.com/security-alerts/cpuapr2020.html"
  }, {
    "type" : "WEB",
    "url" : "https://www.oracle.com/security-alerts/cpuApr2021.html"
  }, {
    "type" : "WEB",
    "url" : "https://www.oracle.com//security-alerts/cpujul2021.html"
  }, {
    "type" : "WEB",
    "url" : "https://security.netapp.com/advisory/ntap-20230818-0001"
  }, {
    "type" : "WEB",
    "url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/WZB3GB7YXIOUKIOQ27VTIP6KKGJJ3CKL"
  }, {
    "type" : "WEB",
    "url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/QLJIK2AUOZOWXR3S5XXBUNMOF3RTHTI7"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/rf5230a049d989dbfdd404b4320a265dceeeba459a4d04ec21873bd55@%3Csolr-user.lucene.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/re13bd219dd4b651134f6357f12bd07a0344eea7518c577bbdd185265@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/rdebc1830d6c09c11d5a4804ca26769dbd292d17d361c61dea50915f0@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/rd3f99d732baed459b425fb0a9e9e14f7843c9459b12037e4a9d753b5@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/rcc35ab6be300365de5ff9587e0479d10d7d7c79070921837e3693162@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r972f82d821b805d04602976a9736c01b6bf218cfe0c3f48b472db488@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r7af60fbd8b2350d49d14e53a3ab2801998b9d1af2d6fcac60b060a53@%3Cdev.brooklyn.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r5caf4fcb69d2749225391e61db7216282955204849ba94f83afe011f@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r590c15cebee9b8e757e2f738127a9a71e48ede647a3044c504e050a4@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r5103b1c9242c0f812ac96e524344144402cbff9b6e078d1557bc7b1e@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r4363c994c8bca033569a98da9218cc0c62bb695c1e47a98e5084e5a0@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r25422df9ad22fec56d9eeca3ab8bd6d66365e9f6bfe311b64730edf5@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r233267e24519bacd0f9fb9f61a1287cb9f4bcb6e75d83f34f405c521@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r21d64797914001119d2fc766b88c6da181dc2308d20f14e7a7f46117@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r204ba2a9ea750f38d789d2bb429cc0925ad6133deea7cbc3001d96b5@%3Csolr-user.lucene.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r05cf37c1e1e662e968cfece1102fcd50fe207181fdbf2c30aadfafd3@%3Cissues.flink.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/9317fd092b257a0815434b116a8af8daea6e920b6673f4fd5583d5fe@%3Ccommits.druid.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/54cc4e9fa6b24520135f6fa4724dfb3465bc14703c7dc7e52353a0ea@%3Ccommits.creadur.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/308cc15f1f1dc53e97046fddbac240e6cd16de89a2746cf257be7f5b@%3Cdev.commons.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/jensdietrich/xshady-release/tree/main/CVE-2019-12402"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-835" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2019-09-30T09:39:36Z",
    "nvd_published_at" : "2019-08-30T09:15:00Z"
  }
}