CVE-2020-7212
Python vulnerability analysis and mitigation

Overview

The _encode_invalid_chars function in util/url.py in the urllib3 library versions 1.25.2 through 1.25.7 for Python allows a denial of service (CPU consumption) due to an inefficient algorithm. The vulnerability was discovered and disclosed in March 2020 (NVD).

Technical details

The vulnerability exists in the _encode_invalid_chars function within the url.py utility module. The issue stems from an inefficient algorithm where the percent_encodings array contains problematic implementation that leads to excessive CPU usage. This affects urllib3 versions from 1.25.2 to 1.25.7 (Ubuntu CVE).

Impact

The vulnerability can be exploited to cause a denial of service condition through CPU consumption, potentially affecting the availability of applications using the affected versions of urllib3 (NVD).

Mitigation and workarounds

The recommended mitigation is to upgrade urllib3 to version 1.25.8 or later which contains the fix for this vulnerability. The fix includes optimizations to the _encode_invalid_chars function to prevent excessive CPU consumption (PyPI).

Additional resources


SourceThis report was generated using AI

Related Python vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

GHSA-5882-5rx9-xgxpCRITICAL10
  • PythonPython
  • crawl4ai
NoYesJan 16, 2026
GHSA-vx9w-5cx4-9796HIGH8.6
  • PythonPython
  • crawl4ai
NoYesJan 16, 2026
CVE-2026-23535HIGH8
  • PythonPython
  • wlc
NoYesJan 16, 2026
CVE-2026-23490HIGH7.5
  • PythonPython
  • pyasn1
NoYesJan 16, 2026
CVE-2026-23528MEDIUM5.3
  • PythonPython
  • distributed
NoYesJan 16, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management