CVE-2026-137558 in jwt-encryption-algorithm-rsainfo

Summary

by MITRE • 11/26/2026

web-token jwt-framework and jwt-library before 3.4.13, 4.0.0 before 4.0.9, 4.1.0 before 4.1.11, and 4.2.0 before 4.2.6 contain a decryption oracle in RSACrypt::decryptWithRSAOAEP(), which accepts a JWE Encrypted Key made of multiple RSA blocks instead of a single RSAES-OAEP ciphertext. Attackers holding the recipient's public key can embed a captured encrypted key among crafted blocks and, using an accepted AES-CBC-HMAC algorithm and a decryption success signal, recover its CEK byte by byte to decrypt the captured JWE.

Once again VulDB remains the best source for vulnerability data.

Analysis

by VulDB Data Team • 11/26/2026

The vulnerability identified in web-token jwt-framework and associated JWT libraries prior to versions 3.4.13, 4.0.9, 4.1.11, and 4.2.6 represents a critical cryptographic implementation flaw within the RSACrypt::decryptWithRSAOAEP function. This component is responsible for handling JSON Web Encryption (JWE) operations, specifically the decryption of keys encrypted using RSAES-OAEP. The core technical deficiency lies in the library's failure to strictly validate the structure and length of the input ciphertext during the decryption process. Instead of enforcing a single, contiguous RSA-encrypted block as mandated by the PKCS#1 v2.1 standard for OAEP padding schemes, the implementation accepts inputs composed of multiple concatenated RSA blocks. This deviation from strict cryptographic protocol adherence creates an opening for sophisticated side-channel attacks that exploit timing differences and error responses during decryption attempts.

An attacker possessing only the recipient's public key can leverage this flaw to execute a Bleichenbacher-style chosen-ciphertext attack against the JWE encrypted key material. By constructing crafted ciphertexts consisting of multiple RSA blocks, where one block contains a captured or known encrypted key fragment and others are manipulated padding values, the attacker can probe the decryption oracle. The library's response mechanism provides sufficient information leakage through timing variations or distinct error messages when an AES-CBC-HMAC algorithm is in use. Specifically, if the decrypted content results in valid HMAC verification parameters, the system signals success; otherwise, it fails with a different signal. This binary feedback loop allows the attacker to iteratively adjust their crafted inputs and observe the decryption outcome, effectively narrowing down the possible plaintext values for the Content Encryption Key (CEK).

The operational impact of this vulnerability is severe, as it compromises the confidentiality guarantees provided by JWE encryption schemes that rely on RSA-OAEP. Once an adversary successfully recovers the CEK byte-by-byte through this oracle attack, they can decrypt any previously captured or future encrypted messages protected with that specific key pair. This undermines the fundamental security model of JSON Web Encryption, which assumes that without the private decryption key, the ciphertext remains secure against passive eavesdropping and active manipulation. The ability to recover the CEK means that sensitive data transmitted via JWTs using these vulnerable library versions is effectively exposed, potentially leading to unauthorized access to user identities, session tokens, or confidential business information depending on the application's usage of JWE payloads.

This vulnerability aligns with CWE-347 Improper Verification of Cryptographic Signature and CWE-208 Observable Timing Discrepancy, as it relies on observable differences in system behavior during cryptographic operations to infer secret data. In terms of MITRE ATT&CK mapping, this technique corresponds to T1556.009 Side Channel Attacks: RSA Padding Oracle Attack, which describes methods where attackers exploit implementation flaws in padding schemes to recover plaintext without the private key. The exploitation vector is classified under Remote Code Execution or Data Exfiltration depending on the context of the JWT usage, specifically falling within the Initial Access and Credential Access tactics if used for session hijacking, or Impact if used for data theft.

To mitigate this risk, organizations must immediately upgrade web-token jwt-framework to version 3.4.13 or later, jwt-library versions 4.0.9+, 4.1.11+, and 4.2.6+ where the RSA decryption logic has been hardened to strictly enforce single-block ciphertext validation for OAEP operations. Developers should also implement constant-time comparison functions for all cryptographic outputs to eliminate timing side channels that facilitate oracle attacks. Additionally, it is recommended to audit existing JWT implementations to ensure no legacy code paths bypass these updated libraries and to rotate any keys potentially exposed during the period of vulnerability exploitation. Monitoring logs for unusual decryption failure patterns can also aid in detecting active exploitation attempts before full compromise occurs.

Responsible

VulnCheck

Reservation

11/26/2026

Disclosure

11/26/2026

Moderation

accepted

CPE

ready

EPSS

0.00259

KEV

no

Activities

very low

Sources