web-token PHP JWT Library padding oracle in RSA1_5 decryption

Severity: medium · CVSS 6.3 · Published 2026-06-18

A vulnerability exists in a popular PHP library used for handling JSON Web Tokens (JWT). The library's implementation of a specific encryption method (RSA1_5) allows an attacker to potentially recover encrypted keys by measuring small differences in how long the server takes to respond to different requests. This could lead to the unauthorized decryption of sensitive data protected by the library.

Technologies: Web-Token JWT Framework, Web-Token JWT Library. Vendors: Web-Token.

Quick answers

Is This vulnerability exploited in the wild?
No. Junglewise Threat Intelligence has no report of This vulnerability being exploited in the wild.
How severe is This vulnerability?
Medium severity, with a CVSS score of 6.3, published 18 June 2026.
Which products and versions are affected?
Web-Token JWT Framework <= 4.1.6; Web-Token JWT Library < 3.4.10, >= 4.0.0 < 4.0.7, >= 4.1.0 < 4.1.7.
Is there a fix for This vulnerability?
No fixed version is recorded yet. Check the vendor's advisory in the references below. If you run it, Junglewise drafts a mitigation that fits your setup and applies it once you approve, with senior security engineers behind it.
How is This vulnerability attacked?
It is attacked over the network, in a software library.
Am I affected?
Check whether you run Web-Token JWT Framework or Web-Token JWT Library at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

Technical details

The vulnerability is a timing side-channel (CWE-208) in the `RSACrypt::decryptWithRSA15()` method. The implementation fails to use implicit rejection as required by RFC 3447/8017; instead, it throws an exception immediately upon detecting malformed padding. This allows a remote attacker to perform a Bleichenbacher-style padding oracle attack by submitting adaptively crafted ciphertexts and measuring the time taken for the server to respond. By distinguishing between padding errors and subsequent processing errors, an attacker can eventually recover the wrapped Content Encryption Key (CEK). Patches have been released in versions 3.4.10, 4.0.7, and 4.1.7 which implement constant-time implicit rejection.

Affected products

  • web-token jwt-library < 3.4.10, >= 4.0.0 < 4.0.7, >= 4.1.0 < 4.1.7
  • web-token jwt-framework <= 4.1.6

Timeline

  • 2026-06-06: disclosed
  • 2026-06-18: advisory

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.