CVE-2016-6581: HPACK Denial of Service vulnerability in hpack

hpack Updated 02 Oct 2025

Summary

05/07/2019
Yes i
High
7.5

CVE-2016-6581: HPACK Denial of Service vulnerability (HPACK Bomb). Affects hpack versions >= 1.0.0, < 2.3.0. Fixed in 2.3.0. How to fix ↓

Also tracked for

The same CVE-2016-6581 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

hpack is a Python library used for HTTP/2 header compression. It provides functionality to compress and decompress headers using the HPACK algorithm. The library is commonly used in HTTP/2 implementations to reduce the size of header data and improve network performance. However, versions between v1.0.0 and v2.2.0 of the hpack library are vulnerable to a denial of service attack known as an "HPACK Bomb".

Vulnerability Detail

The HPACK Bomb attack targets HTTP/2 implementations that use the affected versions of the hpack library. In this attack, an attacker inserts a header field into the dynamic header table that is exactly the size of the table. The attacker then sends a header block consisting of repeated requests to expand that field in the dynamic table. This results in a compression ratio of 4,096 or better, meaning that a small amount of data can decompress to a significantly larger amount on the target machine. This can lead to resource exhaustion and potentially crash the target system.

How To Fix

Latest published version: 4.2.0 as of 22 Oct 2026

pip install --upgrade "hpack==4.2.0"

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

2.3.0

This is the first release that contains the fix.

pip install --upgrade "hpack==2.3.0"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

There is no known workaround for this vulnerability. It is essential to update the hpack library to the fixed version to mitigate the risk of a denial of service attack.

Conclusion

The HPACK Denial of Service vulnerability in the hpack library can be exploited to launch a denial of service attack on systems using the affected versions. To mitigate this risk, it is crucial to update the hpack library to version 2.3.0 or later. For further support and guidance on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for hpack →

Share this vulnerability

FAQ

This vulnerability can be exploited to launch a denial of service attack on systems using the affected versions of the hpack library. The attack can lead to resource exhaustion and potentially crash the target system.

Versions between v1.0.0 and v2.2.0 of the hpack library are vulnerable to this attack. It is recommended to upgrade to version 2.3.0 or later to fix the vulnerability.

No, there is no known workaround for this vulnerability. Updating the hpack library to the fixed version is the only recommended solution.

You can use Vulert's playground at Vulert Scanner to check if your application is affected by this vulnerability. Vulert monitors and alerts in real-time for open-source vulnerabilities, using just Pipfile.lock to provide accurate vulnerability information.

For further support on vulnerability remediation, you can contact info@devnack.com. They can provide assistance and guidance on fixing the vulnerability in your application.

Related vulnerabilities

Recent vulnerabilities recorded for hpack.

How To Fix

Latest published version: 4.2.0 as of 22 Oct 2026

pip install --upgrade "hpack==4.2.0"

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

2.3.0

This is the first release that contains the fix.

pip install --upgrade "hpack==2.3.0"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback