cryptography is vulnerable to Integer Overflow or Wraparound
59
CVE Score
Medium
Integer Overflow or Wraparound
The raw ChaCha20 cipher API treats the first four bytes of the 16-byte nonce as a 32-bit little-endian block counter per RFC 7539. Before the fix, encrypting or decrypting past that counter limit let the underlying implementation silently diverge from RFC 7539 instead of failing. An application that processes enough attacker-influenced data with a near-overflow counter can therefore continue with incorrect keystream material. The library now tracks processed bytes and raises ValueError before the counter would overflow.
Upgrade the cryptography library to the patch version.
You are affected if you are using a version that falls within the vulnerable range and calling the raw ChaCha20 cipher API (not only ChaCha20Poly1305) on attacker-influenced data volumes or nonce counter values.
2.1.0 - 48.0.1
Fixed in 49.0.0cryptography is vulnerable to Integer Overflow or Wraparound in versions 2.1.0 - 48.0.1.
Secure your code, cloud, and runtime in one central system. Connect a repo to discover what the reasoning agents find in your codebase.
No credit card required | Scan results in 32 seconds.
I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant
ISO 42001Compliant© All Intel data is openly available and commercially licensed.