CVE-2026-92599
massRegular expression denial of service (ReDoS) in hapi.js joi isoDate() validation
The joi npm package (the hapi.js schema validation library) is vulnerable to regular expression denial of service (ReDoS, CWE-1333) in the Joi.string().isoDate() validation rule, because one of the regular expressions applied to input is unanchored. A remote attacker who can supply a string that reaches an isoDate() check can trigger quadratic backtracking by sending a valid ISO date followed by a long run of fractional-second digits, taking roughly 1.4 seconds per 64 KB of digits and about 22 seconds per 256 KB. With a single crafted request the attacker can stall the event loop or a request handler, degrading or denying service to the application. Any Node.js service using joi versions 17.2.0 up to (but not including) 18.2.6 that validates attacker-controlled strings with isoDate() is affected. Exploitation is not currently known in the wild, there is no public proof-of-concept, and the flaw is not on the CISA KEV list.
What to do: Upgrade joi to 17.13.7 if you are pinned to the 17.x line, or to 18.2.6 or later on the 18.x line. As a workaround, cap the length of any string (e.g., request-body or field-size limits) before it reaches joi's isoDate() validation. Search your codebase for Joi.string().isoDate() and confirm whether the validated input can be attacker-controlled.
| hapi.js (Sideway) / joi maintainers joi (npm package) | >= 17.2.0 and < 18.2.6 (fixes released as 17.13.7 on the 17.x line and 18.2.6 on the 18.x line) |
Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.
joi (npm package `joi`, hapi.js) versions >=17.2.0 =18.0.0 <18.2.6 are vulnerable to regular expression denial of service in the `Joi.string().isoDate()` validation rule. One of the regular expressions the rule applies to the input is unanchored, so a valid ISO date followed by a long run of fractional-second digits causes the regex engine to restart its search from every position in the string, yielding time proportional to the square of the input length (about 1.4 s for 64 KB of digits and about 22 s for 256 KB). A remote attacker who can supply a string to an isoDate validation can stall the application with a single request. Fixed in 17.13.7 and 18.2.6; as a workaround, cap the length of the string before it reaches joi.
- Weakness
- CWE-1333
- Vector
- CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
In the news0 stories
No ingested article mentions this CVE yet.