Allocation of Resources Without Limits or Throttling Affecting authlib package, versions [,1.6.5)


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Allocation of Resources Without Limits or Throttling vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-PYTHON-AUTHLIB-13535082
  • published12 Oct 2025
  • disclosed10 Oct 2025
  • creditMuhammad Noman Ilyas

Introduced: 10 Oct 2025

NewCVE-2025-62706  (opens in a new tab)
CWE-770  (opens in a new tab)

How to fix?

Upgrade authlib to version 1.6.5 or higher.

Overview

authlib is a library in building OAuth and OpenID Connect servers.

Affected versions of this package are vulnerable to Allocation of Resources Without Limits or Throttling via the DeflateZipAlgorithm.decompress function. An attacker can exhaust memory and CPU resources by submitting specially crafted compressed tokens that, when decrypted, expand to a much larger size than the original input.

Workaround

  • Reject or strip zip=DEF for inbound JWEs at the application boundary until a fix is available.
  • Fork and add a bounded decompression guard (e.g., zlib.decompress(..., max_length) via decompressobj().decompress(data, MAX_SIZE)), returning an error when output exceeds a safe limit.
  • Enforce strict maximum token sizes and fail fast on oversized inputs; combine with rate limiting.

References

CVSS Base Scores

version 4.0
version 3.1