Vulnerability · Published Sep 28, 2026 · Assigned by GitHub_M
CVE-2026-102265PyJWT: Uncaught RecursionError in jwt.decode() on deeply nested token header
Medium 5.3
In plain English
A medium-severity security flaw in pyjwt from jpadilla. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.3% (higher than 28% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
PyJWT is a Python implementation of JSON Web Token standards. From 2.13.0 until 2.14.0, PyJWS._load in jwt/api_jws.py is affected because parser catches ValueError but not RecursionError. This occurs when a deeply nested token header reaches json.loads. As a result, RecursionError escapes the documented PyJWT error hierarchy. Consequently, an unauthenticated malformed token can cause a request-level failure and HTTP 500. This issue is fixed in version 2.14.0.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian:12 | pyjwt | no fix listed | DEBIAN-CVE-2026-102265 |
| Debian:13 | pyjwt | no fix listed | DEBIAN-CVE-2026-102265 |
| Debian:14 | pyjwt | 2.14.0-1 | DEBIAN-CVE-2026-102265 |
| PyPI | pyjwt | 2.14.0 | GHSA-8wjv-2p76-3863 |
| PyPI | pyjwt | 2.14.0 | PYSEC-2026-4142 |
| Ubuntu:22.04:LTS | pyjwt | no fix listed | UBUNTU-CVE-2026-102265 |
| Ubuntu:24.04:LTS | pyjwt | no fix listed | UBUNTU-CVE-2026-102265 |
| Ubuntu:26.04:LTS | pyjwt | no fix listed | UBUNTU-CVE-2026-102265 |
| Ubuntu:26.10 | pyjwt | no fix listed | UBUNTU-CVE-2026-102265 |
Affected products (as reported)
Weakness: CWE-674 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
References
- https://github.com/jpadilla/pyjwt/security/advisories/GHSA-8wjv-2p76-3863 x_refsource_CONFIRM
- https://github.com/jpadilla/pyjwt/commit/06573692ebcdec8831c3927513b3e87c31fbbb62 x_refsource_MISC
- https://github.com/jpadilla/pyjwt/releases/tag/2.14.0 x_refsource_MISC