GHSA-gm62-xv2j-4w53

Suggest an improvement
Source
https://github.com/advisories/GHSA-gm62-xv2j-4w53
Import Source
https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2025/12/GHSA-gm62-xv2j-4w53/GHSA-gm62-xv2j-4w53.json
JSON Data
https://api.osv.dev/v1/vulns/GHSA-gm62-xv2j-4w53
Aliases
Downstream
Published
2025-12-05T18:15:19Z
Modified
2025-12-05T18:52:50.341818Z
Severity
  • 8.9 (High) CVSS_V4 - CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:H CVSS Calculator
Summary
urllib3 allows an unbounded number of links in the decompression chain
Details

Impact

urllib3 supports chained HTTP encoding algorithms for response content according to RFC 9110 (e.g., Content-Encoding: gzip, zstd).

However, the number of links in the decompression chain was unbounded allowing a malicious server to insert a virtually unlimited number of compression steps leading to high CPU usage and massive memory allocation for the decompressed data.

Affected usages

Applications and libraries using urllib3 version 2.5.0 and earlier for HTTP requests to untrusted sources unless they disable content decoding explicitly.

Remediation

Upgrade to at least urllib3 v2.6.0 in which the library limits the number of links to 5.

If upgrading is not immediately possible, use <code>preload_content=False</code> and ensure that resp.headers["content-encoding"] contains a safe number of encodings before reading the response content.

Database specific
{
    "severity": "HIGH",
    "github_reviewed": true,
    "cwe_ids": [
        "CWE-770"
    ],
    "github_reviewed_at": "2025-12-05T18:15:19Z",
    "nvd_published_at": "2025-12-05T16:15:51Z"
}
References

Affected packages

PyPI / urllib3

Package

Affected ranges

Type
ECOSYSTEM
Events
Introduced
1.24
Fixed
2.6.0

Affected versions

1.*

1.24
1.24.1
1.24.2
1.24.3
1.25
1.25.1
1.25.2
1.25.3
1.25.4
1.25.5
1.25.6
1.25.7
1.25.8
1.25.9
1.25.10
1.25.11
1.26.0
1.26.1
1.26.2
1.26.3
1.26.4
1.26.5
1.26.6
1.26.7
1.26.8
1.26.9
1.26.10
1.26.11
1.26.12
1.26.13
1.26.14
1.26.15
1.26.16
1.26.17
1.26.18
1.26.19
1.26.20

2.*

2.0.0a1
2.0.0a2
2.0.0a3
2.0.0a4
2.0.0
2.0.1
2.0.2
2.0.3
2.0.4
2.0.5
2.0.6
2.0.7
2.1.0
2.2.0
2.2.1
2.2.2
2.2.3
2.3.0
2.4.0
2.5.0