Skip to main content

PyJWT CVE-2026-48523

| EUVDEUVD-2026-32918 MEDIUM
Improper Verification of Cryptographic Signature (CWE-347)
2026-05-28 GitHub_M GHSA-jq35-7prp-9v3f PYSEC-2026-176
5.4
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

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

  1. Recon
    Attacker enrolls or compromises JWK key in application JWKS
  2. Delivery
    Signs malicious JWT with disallowed algorithm using private key
  3. Exploit
    Sets JWT header alg to an allowed algorithm to spoof allow-list check
  4. Install
    Submits crafted token to application endpoint
  5. C2
    Application resolves signing key via PyJWKClient (allow-list check passes on header)
  6. Execute
    Signature verified using PyJWK-bound algorithm (passes independently)
  7. Impact
    Token accepted, algorithm policy bypassed

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A04:2025 - Cryptographic Failures
ASVS 5.0
V11 - Cryptography Signature verification
Exploitation Conditions

The attacker must control a registered JWK or JWKS private key that the target application trusts - this is the PR:L (low privilege) requirement confirmed by the CVSS vector. The application must be using the PyJWKClient.get_signing_key_from_jwt() flow specifically, and must call jwt.decode() or jwt.decode_complete() with a PyJWK key object as confirmed by the vulnerability description. The affected version range is strictly 2.9.0 through 2.12.1; deployments outside this range are not affected. Exploitation is limited to parties who are already enrolled as valid key holders - unauthenticated external attackers with no registered key cannot exploit this bypass. Applications that use raw string or bytes keys (rather than PyJWK objects) with jwt.decode() are not affected by this specific code path.

Impact

The CVSS 5.4 Medium score is supported by the vector AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N: the attack is network-reachable, requires no user interaction, and has low complexity, but requires low-level privileges (PR:L), meaning the attacker must already control a registered JWK key in the target application's JWKS. The confidentiality and integrity impacts are limited (C:L/I:L) and there is no availability impact. No EPSS score was provided in the input data, so probabilistic exploitation likelihood cannot be assessed quantitatively. The vulnerability is not listed in CISA KEV and no POC was identified. Despite the moderate CVSS score, the business risk to applications using PyJWKClient for algorithm-restricted verification is meaningful: a bypass of algorithm allow-listing could allow an enrolled party to use weaker or deprecated algorithms that the application explicitly prohibited, potentially undermining cryptographic security properties. Applications that do not use PyJWK objects or the PyJWKClient flow are not affected by this specific bypass path.

Exploit ScenarioDerived

An attacker who has been issued a registered JWK key pair (or has compromised one) in an application's JWKS crafts a JWT: they sign the token using a cryptographically weak or explicitly-disallowed algorithm with their private key, but set the JWT header's alg field to an algorithm that is on the application's allow-list. When the application calls PyJWKClient.get_signing_key_from_jwt() followed by jwt.decode() with the allow-list, the allow-list check passes on the spoofed header value, and the signature verification succeeds because it uses the algorithm bound to the resolved PyJWK object rather than the header-declared one - resulting in the token being accepted despite violating the algorithm policy. No public proof-of-concept has been identified at time of analysis.

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

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

Alert me

AnalysisAIv1 – May 28, 2026

Algorithm allow-list bypass in PyJWT 2.9.0-2.12.1 permits an attacker who controls a registered JWK/JWKS private key to circumvent caller-enforced algorithm restrictions during JWT signature verification. The library correctly checks the token header's alg claim against the caller-supplied allow-list, but then performs the actual cryptographic verification using the algorithm bound to the PyJWK object rather than the header-declared algorithm - creating a exploitable mismatch. Specifically, the documented PyJWKClient.get_signing_key_from_jwt() flow is affected, meaning applications relying on this pattern for algorithm-restricted JWT validation may accept tokens signed with algorithms they explicitly prohibited. No public exploit has been identified at time of analysis and the vulnerability is not listed in CISA KEV.

RemediationAI

Upgrade PyJWT to version 2.13.0, which is the vendor-confirmed fix as detailed in GitHub Security Advisory GHSA-jq35-7prp-9v3f at https://github.com/jpadilla/pyjwt/security/advisories/GHSA-jq35-7prp-9v3f. The fix aligns the algorithm used for signature verification with the caller-supplied allow-list rather than relying solely on the PyJWK object's bound algorithm. As a compensating control if immediate upgrade is not possible, applications can validate that the algorithm declared in the JWT header matches the algorithm bound to the resolved PyJWK object before calling jwt.decode(), and reject tokens where they differ - though this logic must be implemented carefully to avoid introducing new inconsistencies. Alternatively, applications can avoid passing PyJWK objects directly to jwt.decode() and instead extract the raw key material and algorithm explicitly, though this requires changes to the integration pattern. The trade-off of any manual workaround is increased code complexity and ongoing maintenance risk; patching to 2.13.0 is strongly preferred.

Affected VersionsENISA

pyjwt 2.9.0, < 2.13.0

Affected Packages

pypi pyjwt fix: 2.12.1, 2.13.0

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

PyJWT (CPE: cpe:2.3:a:jpadilla:pyjwt:*:*:*:*:*:*:*:*) is a widely used Python library for encoding and decoding JSON Web Tokens per RFC 7519. The root cause is classified as CWE-347 (Improper Verification of Cryptographic Signature), which covers failures to correctly validate the cryptographic guarantees of a signed artifact. In this case, the flaw is an algorithm substitution or confusion attack: the library splits the algorithm validation step (comparing the JWT header's alg field against the caller's allow-list) from the cryptographic operation step (using the algorithm stored on the PyJWK key object). Because these two steps use different algorithm sources, a token whose header advertises an allowed algorithm but whose key object is bound to a different algorithm can pass both checks independently while bypassing the allow-list restriction entirely. This affects the PyJWKClient.get_signing_key_from_jwt() integration path, which is the documented approach for JWKS-based key resolution.

Know when Pyjwt 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_M) PRIMARY 5.4 MEDIUM
AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N
SUSE MEDIUM
Red Hat 5.4 MEDIUM

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

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

Lifecycle Timeline

1
Patch available
May 28, 2026 - 17:01 EUVD

DescriptionCVE.org

PyJWT is a JSON Web Token implementation in Python. From 2.9.0 to 2.12.1, there is a verifier-side algorithm allow-list bypass when jwt.decode() or jwt.decode_complete() are called with a PyJWK key. The token header alg is checked against the caller-supplied algorithms allow-list, but signature verification is performed with the algorithm bound to the PyJWK object instead of the header algorithm. An attacker who controls a registered JWK/JWKS private key can sign with a disallowed algorithm, advertise an allowed algorithm in the JWT header, and still be accepted. The issue affects the documented PyJWKClient.get_signing_key_from_jwt(...) flow. This vulnerability is fixed in 2.13.0.

Blast Radius

ecosystem impact
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 181 pypi packages depend on pyjwt (133 direct, 49 indirect)

Ecosystem-wide dependent count for version 2.9.0.

Threat Intelligence Overview

EPSS Score
0.0%
Top 94% exploitable
Threat Intel
1
1 source
Social Media
1
Sightings
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA Vendor CIRCL GitHub

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 No
EPSS 0.0%
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
Poc
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

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

Attack Technique

Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.

More in Pyjwt

View all
CVE-2026-102266 CRITICAL POC
9.1 Sep 28

Forged HS256 JSON Web Tokens can be accepted as authentic by PyJWT (pip package PyJWT) versions 2.13.0 through 2.13.x wh

CVE-2026-102275 HIGH POC
8.2 Sep 28

Improper validation in PyJWT 2.1.0 through 2.14.0 allows an attacker who already holds a stolen sender-constrained (DPoP

CVE-2026-102274 HIGH POC
7.5 Sep 28

Denial of service in PyJWT 2.9.0 through 2.13.0: a single malformed RSA JWK embedded in a JWK Set aborts construction of

CVE-2026-101918 HIGH POC
7.5 Sep 28

Unauthenticated denial of service in the PyJWT Python library (versions 2.0.0a1 through 2.14.0) allows a remote attacker

CVE-2024-53861 HIGH POC
7.5 Nov 29

pyjwt is a JSON Web Token implementation in Python. Rated high severity (CVSS 7.5), this vulnerability is remotely explo

CVE-2026-48526 HIGH POC
7.4 May 28

Authentication bypass in PyJWT versions prior to 2.13.0 allows remote attackers to forge valid JSON Web Tokens by exploi

CVE-2026-103001 MEDIUM POC
6.5 Sep 30

Reuse of a caller-supplied options mapping in PyJWT 2.11.0 through 2.13.0 can silently leave registered-claim verificati

CVE-2026-102265 MEDIUM POC
5.3 Sep 28

Malformed JSON Web Token headers can cause an uncaught RecursionError in PyJWT 2.13.0 through versions before 2.14.0, re

CVE-2026-48525 MEDIUM POC
5.3 May 28

Uncontrolled resource consumption in PyJWT 2.8.0-2.12.1 exposes any service that verifies detached JWS tokens to unauthe

CVE-2026-102268 CRITICAL
9.1 Sep 28

Signature forgery in PyJWT before 2.14.0 allows an attacker who knows a target's asymmetric public key to forge HMAC-aut

CVE-2026-102267 CRITICAL
9.1 Sep 28

JWKS trust-boundary bypass in PyJWT's PyJWKClient allows a configured trusted JWKS endpoint that returns an HTTP 3xx red

CVE-2026-48524 LOW POC
3.7 May 28

Unconstrained outbound JWKS requests in PyJWT's PyJWKClient.get_signing_key() allow unauthenticated remote attackers to

Vendor StatusVendor

SUSE

Severity: Medium
Product Status
SUSE Linux Enterprise Desktop 15 SP7 Fixed
SUSE Linux Enterprise High Performance Computing 12 Fixed
SUSE Linux Enterprise High Performance Computing 15 SP7 Fixed
SUSE Linux Enterprise Micro 5.5 Fixed
SUSE Linux Enterprise Module for Basesystem 15 SP7 Fixed

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