7.8

CVE-2020-7212: python urllib3 Uncontrolled Resource Consumption

CVSS: 7.8v2.0HighModified
AliasesGHSA-hmv2-79q8-fv6gPYSEC-2020-149UBUNTU-CVE-2020-7212
Published 06-03-2020Last modified 04-08-2024

Vulnerability summary

CVE-2020-7212 is a high (CVSS 7.8) Uncontrolled Resource Consumption vulnerability in python urllib3. EPSS estimates a 3.37% chance of exploitation in the next 30 days, higher than 88.6% of scored vulnerabilities.

Overall risk
32/100
0100
Medium · default modelHow is this calculated?
CVSS score
7.8/10
010
High · v2.0 (NVD)
EPSS score
3.37%
0%100%
Low · 0.00 pp in 30 days
KEVNot listedIn no KEV catalog
RansomwareNone recordedNo known use recorded
Public exploits0No public exploits recorded

Timeline

  1. 06-03-2020
    PublishedVulnerability first disclosed.
  2. 04-08-2024
    Last modifiedVulnerability information updated.

Description

The _encode_invalid_chars function in util/url.py in the urllib3 library 1.25.2 through 1.25.7 for Python allows a denial of service (CPU consumption) because of an inefficient algorithm. The percent_encodings array contains all matches of percent encodings. It is not deduplicated. For a URL of length N, the size of percent_encodings may be up to O(N). The next step (normalize existing percent-encoded bytes) also takes up to O(N) for each step, so the total time is O(N^2). If percent_encodings were deduplicated, the time to compute _encode_invalid_chars would be O(kN), where k is at most 484 ((10+6*2)^2).

CVSS metrics

6 scores · 4 sources · 3 versions

EPSS trend

Probability

3.37%

Chance of exploitation in the next 30 days

Percentile

89%

Versus all other CVEs

30-day change

0.00 pp

From 3.37% on 19-09-2026

19-09-202619-10-2026
EPSS score
3.37%

Known exploited

Compare KEV catalogs

Not in any of the 3 tracked catalogs.

Public exploits

0 found

No public exploits indexed.

Weaknesses

CWE · root cause

Affected systems

Debian1 product
  • python-urllib3< 1.25.8-1
PyPI1 product
  • urllib3< a74c9cfbaed9f811e7563cfc3dce894928e0221a | ≥ 1.25.2, < 1.25.8
Python1 product
Ubuntu1 product
  • python-urllib3< 1.25.8-2

4 vendors · 4 products

References

12 links
Show all 12 references