CVE-2026-48522 Details
Description
PyJWT is a JSON Web Token implementation in Python. Prior to 2.13.0, PyJWKClient passes its uri argument directly to urllib.request.urlopen() which uses Python stdlib's default OpenerDirector registering HTTPHandler, HTTPSHandler, FTPHandler, FileHandler, and DataHandler. There is currently no documented option to restrict which schemes PyJWKClient will fetch. If an application's jku URL ingestion path accepts attacker-influenced URLs (e.g., from JWT header, configuration file, OAuth flow parameter), the attacker can cause PyJWKClient to read arbitrary local files via file:// (SSRF on local filesystem), cause PyJWKClient to attempt FTP / data-URI fetches (broader SSRF surface), or forge tokens that PyJWT verifies as valid. The library does not directly return non-HTTP(S) URI contents to the attacker; the chained "plant a JWKS to forge tokens" scenario described in the original report requires additional application-layer flaws (attacker write access to a filesystem path, untrusted jku derivation) that this fix does not address. This vulnerability is fixed in 2.13.0.
A vulnerability in PyJWT's handling of JSON Web Tokens has been identified in versions through 2.12.1. The issue arises because PyJWKClient passes its 'uri' argument directly to urllib's 'urlopen' function, which accepts various URL schemes including 'file://', 'ftp://', and 'data:'. This lack of validation allows an attacker to exploit applications that ingest URLs from untrusted sources, such as JWT headers or configuration files. The exploitation can lead to several issues: reading arbitrary local files via 'file://' (resulting in server-side request forgery on the local filesystem), initiating FTP or data-URI fetches (broadening the SSRF attack surface), or forging tokens that PyJWT incorrectly verifies as valid. The vulnerability is particularly concerning because, while the library does not directly expose non-HTTP(S) URI contents to the attacker, it can be chained with other application-layer flaws to create a significant security risk.
Users can upgrade to PyJWT version 2.13.0 or later, which addresses this vulnerability by adding a scheme allowlist feature to PyJWKClient.
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 Jun 2, 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-993g-76c3-p5m4 | CISA-ADP | ExploitMitigationVendor Advisory |
| https://github.com/jpadilla/pyjwt/security/advisories/GHSA-993g-76c3-p5m4 | [email protected] | ExploitMitigationVendor Advisory |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-441 | Unintended Proxy or Intermediary ('Confused Deputy') | [email protected] |
| CWE-918 | Server-Side Request Forgery (SSRF) | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| pyjwt project pyjwt | < 2.13.0 |
CPE
Remediation
| |
Change History
5 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| Jun 2, 2026 | CVE Modified | CISA-ADP |
| Jun 1, 2026 | Initial Analysis | [email protected] |
| May 28, 2026 | New CVE Received | [email protected] |