PyJWT: Algorithm allow-list bypass when decoding with `PyJWK` / `PyJWKClient` keys
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.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2026-48523
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 4 Nov 2026, 08:35 UTC · Revision 1
Source evidence
PyJWT: Algorithm allow-list bypass when decoding with `PyJWK` / `PyJWKClient` keys
core-osv · Original sourcePublished 28 May 2026, 15:10 UTC
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.
osv:CVE-2026-48523
Complete source record
{
"id": "41f13e2f62647503d080ebcb2acf0f0f3cd6199b1f96964ddad24df6fead06f4",
"url": "https://osv.dev/vulnerability/CVE-2026-48523",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "PyJWT: Algorithm allow-list bypass when decoding with `PyJWK` / `PyJWKClient` keys",
"summary": "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.",
"evidence": "osv:CVE-2026-48523",
"products": [],
"severity": "medium",
"structured": {
"id": "CVE-2026-48523",
"aliases": [
"CVE-2026-48523",
"GHSA-jq35-7prp-9v3f",
"PYSEC-2026-176"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/jpadilla/pyjwt",
"type": "GIT",
"events": [
{
"introduced": "868cf4ab2ca5a0a39da40e5a14dd740b203662b2"
},
{
"fixed": "7144e4534c34810f4525dc4578a32addd8212cff"
}
],
"database_specific": {
"extracted_events": [
{
"range": [
{
"introduced": "2.9.0"
},
{
"fixed": "2.13.0"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StringRangeExpression"
},
{
"cpe": "cpe:2.3:a:pyjwt_project:pyjwt:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "2.9.0"
},
{
"fixed": "2.13.0"
}
],
"source": "CPE_RANGE"
}
]
}
}
],
"versions": [
"2.12.1",
"2.12.0",
"2.11.0",
"2.10.1",
"2.10.0",
"2.9.0"
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-48523.json"
}
}
],
"modified": "2026-10-28T02:30:33.979697082Z",
"provider": "osv",
"references": [
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/48xxx/CVE-2026-48523.json",
"https://github.com/jpadilla/pyjwt/security/advisories/GHSA-jq35-7prp-9v3f",
"https://nvd.nist.gov/vuln/detail/CVE-2026-48523"
],
"provider_metadata": {
"cwe_ids": [
"CWE-347"
],
"cna_assigner": "GitHub_M",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/48xxx/CVE-2026-48523.json"
}
},
"related_cves": [
{
"value": "CVE-2026-48523",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 501170,
"published_at": "2026-05-28T15:10:19.141+00:00"
}