Skip to main content

Authlib CVE-2025-62706

MEDIUM
Uncontrolled Resource Consumption (CWE-400)
2025-10-22 security-advisories@github.com
6.5
CVSS 3.1 · Vendor: github
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Obtain ability to submit decryptable JWE
  2. Delivery
    Craft tiny zip=DEF compression-bomb token
  3. Exploit
    Send token to JWE decode endpoint
  4. Execution
    Unbounded DEFLATE inflates to hundreds of MB
  5. Persist
    Repeat to exhaust memory and CPU
  6. Impact
    Denial of service / host starvation

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A06:2025 - Insecure Design
ASVS 5.0
V2 - Validation and Business Logic Resource consumption limits
MITRE ATT&CK

1 technique across 1 tactic: Impact

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires that the application uses Authlib's JOSE JWE decode path and accepts/decrypts JWE tokens whose protected header specifies 'zip':'DEF' (DEFLATE compression), on versions prior to 1.6.5. The attacker must be able to supply a token the target will actually decrypt - i.e. possess or control the relevant decryption key material or operate within a trust relationship that accepts externally-supplied JWEs (reflected by PR:L). Limiting factors: services that never enable/accept zip=DEF, that strip or reject compressed JWEs at the boundary, that enforce strict maximum token sizes and rate limiting, or that already run 1.6.5+ are not exploitable. No end-user interaction is required (UI:N). Impact is availability-only (memory/CPU exhaustion); no data disclosure or modification occurs.

Impact

This is a genuine but moderate-priority availability issue rather than a critical emergency. The CVSS vector (AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H, base 6.5) correctly captures a network-reachable, low-complexity attack with no confidentiality or integrity impact and high availability impact - a classic CWE-400 resource-exhaustion (decompression bomb) profile. Multiple signals align and should temper urgency: EPSS is only 0.46% (38th percentile), there is NO CISA KEV listing (no evidence of active exploitation), and the only impact is denial of service. These point to low real-world mass-exploitation likelihood. Countervailing the low EPSS, publicly available exploit/PoC code exists (the vendor GHSA ships a working jwe_deflate_dos_demo.py), which lowers the skill barrier and makes opportunistic DoS against exposed Authlib JOSE endpoints plausible. One important nuance that limits risk: the PR:L in the vector and the description ('an attacker who can supply decryptable tokens') mean the attacker must be able to produce JWEs the target will actually decrypt - i.e. possess or control the relevant key material or a trust relationship - so this is not a trivially anonymous internet-wide attack. SSVC-style reading: exploitation=PoC, automatable=likely yes (repeatable crafted tokens), technical impact=partial (availability only). Net: patch in due course, prioritize internet-facing services that accept third-party or externally-issued JWE tokens with zip=DEF, but this does not rise to drop-everything severity.

Exploit ScenarioDerived

An attacker who can submit a JWE the service will decrypt crafts a tiny zip=DEF (DEFLATE) ciphertext containing highly repetitive data that inflates to tens or hundreds of megabytes on decompression. When Authlib's JWE decode path decompresses it without a size bound, the target process spikes RSS and CPU; repeating the request across connections starves the host and causes denial of service. Public PoC code (jwe_deflate_dos_demo.py in the vendor advisory GHSA-g7f3-828f-7h7m) demonstrates the amplification, lowering the barrier to reproduce.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.5% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Oct 19, 2026

Unbounded DEFLATE decompression in Authlib's JWE zip=DEF handling (authlib/jose/rfc7518/jwe_zips.py) lets a small, valid ciphertext expand into hundreds of megabytes during decrypt, exhausting memory and CPU on services running versions prior to 1.6.5. Attackers must be able to supply a JWE the application will actually decrypt - typically through possession of key material or an endpoint accepting externally-supplied encrypted tokens - and the impact is availability-only with no disclosure or modification (CVSS 6.5, PR:L, A:H). A public proof-of-concept and a hardened comparison implementation exist, but exploitation requires the application to accept zip=DEF tokens; no confirmed active exploitation is reported, and EPSS is low at 0.46% (38th percentile).

RemediationAI

Upgrade to Authlib 1.6.5, which bounds decompression at 250 KB and raises ValueError on oversized output; see advisory https://github.com/authlib/authlib/security/advisories/GHSA-g7f3-828f-7h7m and patch commit https://github.com/authlib/authlib/commit/e0863d5129316b1790eee5f14cece32a03b8184d (Debian users should apply the LTS update from lists.debian.org/debian-lts-announce/2025/10/msg00032.html). If upgrading is delayed: reject or strip 'zip':'DEF' from inbound JWE protected headers at the application boundary (rejects legitimate compressed tokens with a small bandwidth cost), fork and add a bounded guard via decompressobj().decompress(data, MAX_SIZE) returning an error when unconsumed_tail remains, or enforce strict maximum token sizes and fail fast on oversized inputs - and combine these with rate limiting to blunt repeated flooding attempts. Note these workarounds reduce functionality or require maintaining a vendor patch fork, so upgrading remains the preferred fix.

Affected Packages

pypi authlib fix: 1.6.5

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Authlib is a Python library implementing OAuth 1/2 and OpenID Connect, including a JOSE stack (RFC 7516 JWE, RFC 7518 JWA). RFC 7518 defines the 'zip' header with the 'DEF' value, meaning the plaintext is DEFLATE-compressed before encryption; on decode, Authlib's DeflateZipAlgorithm.decompress called zlib.decompress(s, -zlib.MAX_WBITS) with raw-deflate mode and no output bound, and jwe.py assigned the full inflated buffer to the plaintext field. Since DEFLATE can exceed 1000:1 ratios on repetitive input, a tiny ciphertext became a decompression bomb (CWE-400, uncontrolled resource consumption). The upstream fix detects the gzip header (bytes 120,156) and uses zlib.decompressobj() with a 250 KB (MAX_SIZE) limit, raising ValueError when decompressor.unconsumed_tail is non-empty - mirroring the joserfc project's 256 KB ExceededSizeError guard.

Know when Authlib gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (github) PRIMARY 6.5 MEDIUM
AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
vuln.today AI 6.5 MEDIUM

Network-reachable DEFLATE bomb is low-complexity and needs no user interaction, but attacker must supply a decryptable token (PR:L); impact is availability-only, so C:N/I:N/A:H.

3.1 AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
4.0 AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (github).

CVSS VectorVendor: github

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

DescriptionCVE.org

Authlib is a Python library which builds OAuth and OpenID Connect servers. Prior to version 1.6.5, Authlib’s JWE zip=DEF path performs unbounded DEFLATE decompression. A very small ciphertext can expand into tens or hundreds of megabytes on decrypt, allowing an attacker who can supply decryptable tokens to exhaust memory and CPU and cause denial of service. This issue has been patched in version 1.6.5. Workarounds for this issue involve rejecting or stripping zip=DEF for inbound JWEs at the application boundary, forking and add a bounded decompression guard via decompressobj().decompress(data, MAX_SIZE)) and returning an error when output exceeds a safe limit, or enforcing strict maximum token sizes and fail fast on oversized inputs; combine with rate limiting.

Threat Intelligence Overview

EPSS Score
0.5%
Top 62% exploitable
Prevalence
Medium
popular Python OAuth/OIDC library, common but not universally deployed
Exploit
POC
Public exploit code exists
Data Quality
4 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC Yes
EPSS 0.5%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
Poc
System Exposure· derived
Open
Automatable· derived
No
Human Impact· derived
Medium

Priority Score

52
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +32
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

Affected Products (CPE)CVE.org

cpe:2.3:a:authlib:authlib:*:*:*:*:*:*:*:*
CVE-2025-68158 HIGH POC
8.8 Jan 08

Authlib is a Python library which builds OAuth and OpenID Connect servers. [CVSS 5.7 MEDIUM]

CVE-2026-28802 HIGH POC
7.7 Mar 06

Authentication bypass in Authlib (Python OAuth/OpenID Connect library) versions 1.6.5 through 1.6.6 allows remote attack

CVE-2025-59420 HIGH POC
7.5 Sep 22

Authlib is a Python library which builds OAuth and OpenID Connect servers. Rated high severity (CVSS 7.5), this vulnerab

CVE-2025-61920 HIGH POC
7.5 Oct 10

Authlib's JOSE/JWS verification path (through 1.6.4, with 1.6.5 as the fix) decodes attacker-supplied JWT/JWS header and

CVE-2024-37568 HIGH POC
7.5 Jun 09

lepture Authlib before 1.3.1 has algorithm confusion with asymmetric public keys. Rated high severity (CVSS 7.5), this v

CVE-2026-96760 CRITICAL
9.8 Sep 28

Signature verification bypass in Authlib 1.7.2 and earlier allows unauthenticated remote attackers to have crafted JWS J

CVE-2026-104056 CRITICAL
9.8 Oct 01

Poisoned OAuth/OIDC discovery metadata in Authlib 1.7.2 and earlier allows an attacker who controls or intercepts the me

CVE-2026-102946 CRITICAL
9.1 Oct 15

Authentication bypass in the joserfc Python library before 1.7.4 lets remote, unauthenticated attackers submit a JWS Gen

CVE-2026-114616 HIGH
7.4 Oct 22

Token forgery in the Authlib Python library before 1.9.1 lets a remote, unauthenticated attacker mint HS256, HS384 or HS

CVE-2026-114615 HIGH
7.4 Oct 22

Authentication bypass in Authlib's deprecated-but-still-shipped authlib.jose module (1.3.1 through 1.8.0, fixed in 1.9.0

CVE-2026-114618 MEDIUM
6.8 Oct 22

Authlib's default RFC 7523 JWT bearer grant, in all releases prior to 1.9.0, fails to bind an incoming JWT assertion to

CVE-2026-114620 MEDIUM
5.4 Oct 22

Server-side request forgery in Authlib's RFC 9101 JWTAuthenticationRequest (JAR) extension lets unauthenticated remote a

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy