Critical SSL Verification Bypass in urllib3 Package

python-urllib3 Updated 02 Oct 2025

Summary

18/04/2019
N/A
Yes i
High
7.5

CVE-2019-11324: The urllib3 library before 1.24.2 for Python mishandles certain cases where the desired set of CA certificates is different from the OS store of CA certificates, which results in SSL connections succeeding in situations... Affects python-urllib3 across 2 version ranges.

< 1.25.6-4 < 1efadf43dc63317cd9eaa3e0fdb9e05ab07254b1

Fixed in 1.25.6-4. How to fix ↓

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 MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

urllib3 is a powerful, user-friendly HTTP client for Python, widely used for making HTTP requests. It provides features such as connection pooling, client-side SSL/TLS verification, and support for various HTTP methods. However, prior to version 1.24.2, urllib3 mishandled certain cases where the desired set of CA certificates differed from the operating system's store, leading to potential SSL verification failures.

Vulnerability Detail

The vulnerability, identified as CVE-2019-11324, arises from improper handling of SSL certificate verification in urllib3 versions before 1.24.2. This flaw allows SSL connections to succeed even when they should fail due to verification issues, potentially exposing users to man-in-the-middle attacks. The problem is linked to the use of the ssl_context, ca_certs, or ca_certs_dir arguments, which can lead to insecure connections if not configured correctly.

How To Fix

Minimum fixed version

1.25.6-4

This is the first release that contains the fix.

sudo apt-get install --only-upgrade python-urllib3

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

Workaround

If upgrading is not immediately possible, consider using a custom SSL context that enforces stricter verification. This can be done by creating an SSL context in your code as follows:

import ssl import urllib3

Create a custom SSL context

ssl_context = ssl.create_default_context()
ssl_context.verify_mode = ssl.CERT_REQUIRED

Use the custom context in your urllib3 connection

http = urllib3.PoolManager(ssl_context=ssl_context)

Conclusion

CVE-2019-11324 represents a significant security risk for applications using vulnerable versions of urllib3. It is crucial for developers to upgrade to the latest version to ensure secure SSL connections and protect against potential attacks. Utilizing tools like Vulert can help monitor and manage vulnerabilities effectively.

See every vulnerability recorded for python-urllib3 →

Share this vulnerability

FAQ

CVE-2019-11324 is a vulnerability in the urllib3 library that allows SSL connections to succeed even when they should fail due to certificate verification issues.

You can check if your application is affected by using the Vulert playground at Vulert Scanner, which allows you to monitor and alert for open-source vulnerabilities without any signup.

The primary risk is exposure to man-in-the-middle attacks, where an attacker could intercept and manipulate data being transmitted over SSL connections.

The CVSS score for CVE-2019-11324 is 7.5, indicating a high severity level.

Yes, you can create a custom SSL context that enforces stricter verification as a temporary workaround until you can upgrade.

Related vulnerabilities

Recent vulnerabilities recorded for python-urllib3.

How To Fix

Minimum fixed version

1.25.6-4

This is the first release that contains the fix.

sudo apt-get install --only-upgrade python-urllib3

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