CVE-2026-102268 Details
Description
PyJWT is a Python implementation of JSON Web Token standards. Prior to 2.14.0, is_pem_format in jwt/utils.py is affected because is_pem_format does not recognize every PEM representation accepted by the cryptography loader. This occurs when an application mixes HMAC and asymmetric algorithms and supplies a mutated public-key PEM as raw key bytes. As a result, HMACAlgorithm.prepare_key treats the unrecognized asymmetric public key as an HMAC secret. Consequently, an attacker who knows the public key can forge authenticated HMAC tokens. This issue is fixed in version 2.14.0.
A vulnerability in PyJWT prior to version 2.14.0 allows for token forgery by exploiting improper PEM format recognition in the 'is_pem_format' function. This issue arises when an application combines HMAC and asymmetric algorithms, and a mutated public-key PEM is provided as raw key bytes. The 'HMACAlgorithm.prepare_key' method mistakenly treats the unrecognized asymmetric public key as an HMAC secret. Consequently, an attacker with knowledge of the public key can forge authenticated HMAC tokens. The vulnerability is present in versions of PyJWT through 2.13.0.
Users can upgrade to PyJWT version 2.14.0, which addresses this vulnerability by improving the PEM format recognition to correctly identify and reject malformed keys that could be exploited.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed Sep 29, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/jpadilla/pyjwt/security/advisories/GHSA-ffc3-869f-jxw9 | CISA-ADP | ExploitVendor Advisory |
| https://github.com/jpadilla/pyjwt/commit/8b4e233a22206b34ec1186e912e75c0b2396ac07 | [email protected] | Patch |
| https://github.com/jpadilla/pyjwt/releases/tag/2.14.0 | [email protected] | ProductRelease Notes |
| https://github.com/jpadilla/pyjwt/security/advisories/GHSA-ffc3-869f-jxw9 | [email protected] | ExploitVendor Advisory |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-347 | Improper Verification of Cryptographic Signature | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| pyjwt project pyjwt | < 2.14.0 |
CPE
Remediation
| |
Change History
3 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Oct 7, 2026 | Initial Analysis | [email protected] |
| Sep 29, 2026 | CVE Modified | CISA-ADP |
| Sep 28, 2026 | New CVE Received | [email protected] |