Critical Memory Handling Vulnerability in python-cryptography Package

python-cryptography Updated 03 Oct 2025

Summary

27/05/2024
N/A
Yes i
Unrated
Not published

USN-6673-3: python-cryptography vulnerability. Affects python-cryptography versions < 41.0.7-4ubuntu0.1. Fixed in 41.0.7-4ubuntu0.1. 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 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

The python-cryptography package is a widely used library in Python that provides cryptographic recipes and primitives to developers. It is essential for secure communication and data protection in various applications. This library supports various encryption algorithms and protocols, making it a critical component in many software systems. However, it has recently been identified that certain versions of this package are vulnerable to a memory handling issue that could lead to denial of service under specific conditions.

Vulnerability Detail

The vulnerability, identified as CVE-2024-26130, arises from improper handling of memory operations when processing mismatched PKCS#12 keys. This flaw can be exploited by a remote attacker to cause the python-cryptography library to crash, resulting in a denial of service. This issue specifically affects Ubuntu 23.10, but the update has been provided for Ubuntu 24.04 LTS to mitigate the risk. The vulnerability highlights the importance of robust memory management in cryptographic libraries, as failures can lead to significant security risks.

How To Fix

Minimum fixed version

41.0.7-4ubuntu0.1

This is the first release that contains the fix.

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

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

Workaround

Currently, there are no specific workarounds mentioned for this vulnerability. The best course of action is to apply the available patch by updating the package as described above.

Conclusion

The python-cryptography package has a critical vulnerability that can lead to denial of service due to improper memory handling. Users are strongly advised to update to the patched version to ensure their applications remain secure. Regular monitoring for vulnerabilities using tools like Vulert can help maintain the integrity of your software.

See every vulnerability recorded for python-cryptography →

Share this vulnerability

FAQ

CVE-2024-26130 is a vulnerability in the python-cryptography package that involves improper memory handling when processing mismatched PKCS#12 keys, potentially leading to denial of service.

The vulnerability specifically affects the python-cryptography package in Ubuntu 23.10. However, an update has been released for Ubuntu 24.04 LTS.

You can use Vulert, which monitors and alerts for open-source vulnerabilities in your software. By using the Vulert playground, you can check if your application is affected by this vulnerability without any signup.

While there are no specific workarounds available, it is crucial to prioritize updating the package to mitigate the risk associated with this vulnerability.

More details can be found in the official advisory linked in the vulnerability report, which provides comprehensive information about the issue and its implications.

Related vulnerabilities

Recent vulnerabilities recorded for python-cryptography.

How To Fix

Minimum fixed version

41.0.7-4ubuntu0.1

This is the first release that contains the fix.

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

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