Uncontrolled Recursion Affecting pyjwt package, versions [2.13.0,2.14.0)


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.29% (20th percentile)

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 Uncontrolled Recursion vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-PYTHON-PYJWT-20246764
  • published29 Sept 2026
  • disclosed28 Sept 2026
  • creditNivid42

Introduced: 28 Sep 2026

NewCVE-2026-102265  (opens in a new tab)
CWE-674  (opens in a new tab)

How to fix?

Upgrade PyJWT to version 2.14.0 or higher.

Overview

PyJWT is a Python implementation of RFC 7519.

Affected versions of this package are vulnerable to Uncontrolled Recursion via the _load method in jwt/api_jws.py when parsing a JWT with a deeply nested recursive JSON structure in the header. An attacker can supply a JWT whose header contains deeply nested JSON objects, triggering unbounded recursion in the JSON parser and causing a RecursionError that crashes the process. Prior to the fix, RecursionError was not caught alongside ValueError, so it propagated as an unhandled exception instead of being converted to a DecodeError.

CVSS Base Scores

version 4.0
version 3.1