Junglewise Threat Intelligence

CVE-2026-39373: Latchset JWCrypto denial of service via memory exhaustion in JWE decompression

CVE-2026-39373 · Severity: medium · CVSS 5.3 · Published 2026-04-07

Technologies: jwcrypto (PyPI). Vendors: PyPI.

Executive brief

JWCrypto is a Python library used to implement encrypted and signed web tokens (JWT/JWE). A vulnerability exists where the library fails to properly limit the size of data after it has been decompressed. An unauthenticated attacker can send a specially crafted, small encrypted token that expands significantly when processed, potentially crashing the application or server by exhausting its available memory.

Technical details

JWCrypto prior to version 1.5.7 is vulnerable to a data amplification (ZIP bomb) attack in its JWE decryption/decompression logic. While a previous fix (CVE-2024-28102) limited the input token size to 250KB, the library still fails to validate the size of the output after decompression. An unauthenticated remote attacker can provide a crafted JWE token with the 'zip' header set to 'DEF' that remains under the input limit but expands to approximately 100MB in memory. This can lead to denial-of-service via memory exhaustion, particularly on memory-constrained systems. The issue is rooted in the use of zlib.decompress without an explicit limit on the resulting plaintext size. This is fixed in version 1.5.7.

Affected products

  • latchset jwcrypto < 1.5.7

Timeline

  • 2026-04-07: disclosed
  • 2026-04-07: advisory
  • 1.5.7: patched

References

Related threats