Python-cryptography: bleichenbacher timing oracle attack against rsa decryption - incomplete fix for cve-2020-25659
Description
A flaw was found in the python-cryptography package. This issue may allow a remote attacker to decrypt captured messages in TLS servers that use RSA key exchanges, which may lead to exposure of confidential or sensitive data.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
A timing side-channel in python-cryptography's RSA PKCS#1 v1.5 decryption allows remote attackers to decrypt captured TLS traffic using an improved Bleichenbacher-style oracle attack.
Root
Cause
The vulnerability is an incomplete fix for [CVE-2020-25659] in the python-cryptography package. The RSA PKCS#1 v1.5 decryption code did not fully eliminate timing side-channel differences, leaving a detectable oracle that distinguishes between valid and invalid padding [1][3]. This flaw is acknowledged in the upstream documentation as a known limitation [4].
Attack
Vector
An attacker on the network could capture TLS ciphertexts from sessions using RSA key exchange and then send crafted malformed ciphertexts to the server, measuring response times. The timing difference observed—approximately 400 nanoseconds—is sufficient for remote exploitation, as demonstrated with statistical analysis [4]. No authentication is required beyond the ability to initiate TLS connections.
Impact
Successful exploitation allows the attacker to decrypt the captured TLS messages, exposing any confidential data transported over the session (e.g., session keys, authentication tokens, or sensitive payloads) [2]. The vulnerability affects TLS servers that use RSA key agreement; servers using ephemeral Diffie-Hellman (DHE/ECDHE) are not exposed.
Mitigation
Red Hat has rated the severity as Medium. Patched versions of python-cryptography are available; users should upgrade to the latest release to eliminate the timing oracle [1][3]. Systems still using RSA key exchange in TLS should consider migrating to forward-secrecy ciphersuites as a general security best practice.
AI Insight generated on May 20, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
cryptographyPyPI | < 42.0.0 | 42.0.0 |
Affected products
1- Range: 0.1, 0.2, 0.3, …
Patches
0No patches discovered yet.
Vulnerability mechanics
AI mechanics synthesis has not run for this CVE yet.
References
6- github.com/advisories/GHSA-3ww4-gg4f-jr7fghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2023-50782ghsaADVISORY
- access.redhat.com/security/cve/CVE-2023-50782ghsavdb-entryx_refsource_REDHATWEB
- bugzilla.redhat.com/show_bug.cgighsaissue-trackingx_refsource_REDHATWEB
- github.com/pyca/cryptography/issues/9785ghsaWEB
- www.couchbase.com/alertsghsaWEB
News mentions
0No linked articles in our index yet.