Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-102275 Overview
CVE-2026-102275 affects PyJWT, the widely used Python implementation of the JSON Web Token (JWT) standard. The flaw resides in OKPAlgorithm.from_jwk within jwt/algorithms.py. When importing an Octet Key Pair (OKP) private JSON Web Key (JWK), the library does not verify that the public key derived from the d component matches the supplied x component. This mismatch breaks the binding between key identity and cryptographic operations. Attackers can leverage this weakness against integrations that accept private key parameters from proof headers, enabling reuse of stolen sender-constrained tokens without possessing the legitimate private key. Versions from 2.1.0 up to (but not including) 2.15.0 are affected.
Critical Impact
An attacker with a stolen sender-constrained JWT can bypass proof-of-possession checks by supplying an OKP JWK whose x and d components do not correspond, undermining token binding.
Affected Products
- PyJWT versions 2.1.0 through 2.14.x
- Applications using OKPAlgorithm.from_jwk with Ed25519 or Ed448 keys
- Services accepting private JWK parameters from proof headers (e.g., DPoP-style integrations)
Discovery Timeline
- 2026-09-28 - CVE-2026-102275 published to the National Vulnerability Database (NVD)
- 2026-09-30 - Last updated in NVD database
Technical Details for CVE-2026-102275
Vulnerability Analysis
The vulnerability is an insufficient verification of data authenticity issue [CWE-345] in PyJWT's OKP JWK import path. An OKP JWK for Ed25519 or Ed448 keys contains an x parameter (the public key bytes) and, for a private key, a d parameter (the private key bytes). A well-formed private JWK must satisfy the invariant that the public key derived from d equals x. PyJWT did not enforce that invariant. Consequently, the library would accept a JWK where the public identity (x) diverges from the actual signing material (d). Downstream code that treats x as the sender's identifier while performing operations with d operates on inconsistent state.
Root Cause
Inside OKPAlgorithm.from_jwk, the private branch decoded d and returned an Ed25519PrivateKey or Ed448PrivateKey directly, without deriving the corresponding public key and comparing it against the decoded x. Missing cross-parameter validation is the root cause.
Attack Vector
Exploitation requires a network-reachable relying party that accepts private JWK material from an untrusted source, such as a proof header on a sender-constrained token. An attacker who has stolen a legitimate sender-constrained token can craft a JWK where x matches the victim's expected public key but d is the attacker's private key. If the relying party imports this JWK through the vulnerable code path and uses x for token binding while accepting signatures produced with d, the attacker replays the stolen token as if they possessed the sender's key.
return Ed25519PublicKey.from_public_bytes(x)
return Ed448PublicKey.from_public_bytes(x)
d = base64url_decode(obj.get("d"))
+ private_key: Ed25519PrivateKey | Ed448PrivateKey
if curve == "Ed25519":
- return Ed25519PrivateKey.from_private_bytes(d)
- return Ed448PrivateKey.from_private_bytes(d)
+ private_key = Ed25519PrivateKey.from_private_bytes(d)
+ else:
+ private_key = Ed448PrivateKey.from_private_bytes(d)
+ if (
+ private_key.public_key().public_bytes(
+ encoding=Encoding.Raw, format=PublicFormat.Raw
+ )
+ != x
+ ):
+ raise InvalidKeyError("Public key does not match private key")
+ return private_key
except ValueError as err:
raise InvalidKeyError("Invalid key parameter") from err
Source: PyJWT patch commit 3cd9cee. The fix derives the public key from d and raises InvalidKeyError when it does not equal the supplied x.
Detect Identity Attacks the Moment Authentication Fails
Singularity™ Identity surfaces credential misuse, lateral movement, and privilege escalation in real time, so you can contain the breach before it spreads.
Stop Identity AttacksDetection Methods for CVE-2026-102275
Indicators of Compromise
- Requests containing JWT proof headers with embedded private JWK parameters (d) received from untrusted clients.
- Successful authentication events where the presenting client cannot demonstrate possession of the expected private key.
- Repeated replay of the same sender-constrained token from multiple source IPs or user agents.
Detection Strategies
- Inventory Python dependencies for PyJWT versions between 2.1.0 and 2.14.x using SBOM or SCA tooling.
- Perform code review for direct or transitive calls to OKPAlgorithm.from_jwk that ingest attacker-controlled JWK data.
- Log and alert on JWK imports that raise InvalidKeyError after upgrading, since these may indicate exploitation attempts.
Monitoring Recommendations
- Instrument authentication services to record JWK import failures and correlate them with source identity and request metadata.
- Monitor for anomalous DPoP-style proof headers containing private key material, which should never appear in legitimate flows.
- Alert on JWT verification anomalies tied to Ed25519 or Ed448 key operations across identity brokers.
How to Mitigate CVE-2026-102275
Immediate Actions Required
- Upgrade PyJWT to version 2.15.0 or later across all Python services and container images.
- Audit application code to ensure JWK parsing never accepts private key parameters (d) from untrusted sources such as proof headers.
- Rotate any sender-constrained tokens and associated keys that may have been exposed through vulnerable integrations.
Patch Information
The issue is fixed in PyJWT 2.15.0. See the PyJWT 2.15.0 release notes and GitHub Security Advisory GHSA-x33g-cr3x-6449 for details.
Workarounds
- Reject JWTs and proof headers that include private key parameters before invoking OKPAlgorithm.from_jwk.
- Validate that the derived public key from any imported OKP private JWK matches the sender's registered public key.
- Restrict JWK import paths so that only public JWKs are ever parsed on the relying party side.
# Upgrade PyJWT to the patched release
pip install --upgrade "PyJWT>=2.15.0"
# Verify installed version
python -c "import jwt; print(jwt.__version__)"
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

