# CVE-2024-26308: Apache Commons Compress: OutOfMemoryError unpacking broken Pack200 file

> Attackers can cause denial of service via OutOfMemoryError by providing a broken Pack200 file to applications using this library.

- **Severity:** Medium 5.5 (`CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Local or same network only
- **Victim action needed:** A user has to click or open something
- **Fix available:** Yes
- **Published:** 19 Feb 2024
- **Updated:** 27 Mar 2025
- **Also known as:** CLEANSTART-2026-DR01858, CLEANSTART-2026-TZ12135, DEBIAN-CVE-2024-26308, ECHO-db89-1b8d-3c4a, GHSA-4265-ccf5-phj5, MINI-4237-j7vw-7vq4, MINI-8wq2-5hcc-cm56, MINI-gr37-4jp2-245j, MINI-p8p8-74x2-8cjm, MINI-qcmr-6j5v-748h, MINI-r8x4-c4w6-jjwq, MINI-vw3v-x3xr-rgf5, ROOT-APP-MAVEN-CVE-2024-26308, UBUNTU-CVE-2024-26308

## What is CVE-2024-26308?

CVE-2024-26308 is a medium-severity denial of service vulnerability in Apache Commons Compress, published on 19 Feb 2024. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.

### Official description

Allocation of Resources Without Limits or Throttling vulnerability in Apache Commons Compress.This issue affects Apache Commons Compress: from 1.21 before 1.26.

Users are recommended to upgrade to version 1.26, which fixes the issue.

Weakness: CWE-770 (Allocation of Resources Without Limits or Throttling)

## Which versions are affected by CVE-2024-26308?

2 open source packages ship an affected version, including org.apache.commons:commons-compress. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `org.apache.commons:commons-compress` | Maven | From 1.21 | 1.26.0 |
| `org.apache.commons:commons-compress` | Maven | From 1.21 | 1.26.0 |

Products: Apache Commons Compress.

## How do I fix CVE-2024-26308?

Upgrade org.apache.commons:commons-compress to 1.26.0 or later.

## Is CVE-2024-26308 being exploited?

There is no known exploitation of CVE-2024-26308 in the wild and no public exploit code.

Public exploit code:

- Docker Deskop giving issue CVE-2024-26308 for maven [reproduce] (github_poc): https://github.com/crazycatMyopic/cve

## Other vulnerabilities in Apache Commons Compress

- [CVE-2024-25710](https://insights.sbomify.com/CVE-2024-25710/): Apache Commons Compress: Denial of service caused by an infinite loop for a corrupted DUMP file (high 8.1)
- [CVE-2021-35515](https://insights.sbomify.com/CVE-2021-35515/): Apache Commons Compress 1.6 to 1.20 denial of service vulnerability (high 7.5)
- [CVE-2021-35516](https://insights.sbomify.com/CVE-2021-35516/): Apache Commons Compress 1.6 to 1.20 denial of service vulnerability (high 7.5)
- [CVE-2021-35517](https://insights.sbomify.com/CVE-2021-35517/): Apache Commons Compress 1.1 to 1.20 denial of service vulnerability (high 7.5)
- [CVE-2021-36090](https://insights.sbomify.com/CVE-2021-36090/): Apache Commons Compress 1.0 to 1.20 denial of service vulnerability (high 7.5)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2024-26308 and fix it if it is affected.

What it is: CVE-2024-26308 is a medium-severity denial of service vulnerability in Apache Commons Compress, published on 19 Feb 2024. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.
Exploitation: There is no known exploitation of CVE-2024-26308 in the wild and no public exploit code.

Affected packages and fixed versions:
- org.apache.commons:commons-compress (Maven): affected from 1.21; fixed in 1.26.0
- org.apache.commons:commons-compress (Maven): affected from 1.21; fixed in 1.26.0

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2024-26308/ (Markdown: https://insights.sbomify.com/CVE-2024-26308/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2024-26308
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2024-26308
- OSV: https://osv.dev/vulnerability/CVE-2024-26308

---
From sbomify Insights: https://insights.sbomify.com/CVE-2024-26308/
Summaries are generated and may contain mistakes; the official description above is the record.
