CVE-2023-48223Improper Input Validation in Fast-jwt

Severity
9.1CRITICALNVD
NVD5.9GHSA5.9OSV5.9
EPSS
0.2%
top 60.50%
CISA KEV
Not in KEV
Exploit
No known exploits
Affected products
Timeline
PublishedNov 20
Latest updateApr 2

Description

fast-jwt provides fast JSON Web Token (JWT) implementation. Prior to version 3.3.2, the fast-jwt library does not properly prevent JWT algorithm confusion for all public key types. The 'publicKeyPemMatcher' in 'fast-jwt/src/crypto.js' does not properly match all common PEM formats for public keys. To exploit this vulnerability, an attacker needs to craft a malicious JWT token containing the HS256 algorithm, signed with the public RSA key of the victim application. This attack will only work if t

CVSS vector

CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:NExploitability: 2.2 | Impact: 3.6

Affected Packages3 packages

NVDnearform/fast-jwt< 3.3.2
npmnearform/fast-jwt< 6.2.0+1
CVEListV5nearform/fast-jwt6.1.0

🔴Vulnerability Details

4
OSV
fast-jwt: Incomplete fix for CVE-2023-48223: JWT Algorithm Confusion via Whitespace-Prefixed RSA Public Key2026-04-02
GHSA
fast-jwt: Incomplete fix for CVE-2023-48223: JWT Algorithm Confusion via Whitespace-Prefixed RSA Public Key2026-04-02
OSV
JWT Algorithm Confusion2023-11-20
GHSA
JWT Algorithm Confusion2023-11-20

🕵️Threat Intelligence

1
Wiz
CVE-2026-34950 Impact, Exploitability, and Mitigation Steps | Wiz