CVE-2026-84368 is a low-severity (CVSS 3.7) CWE-1321 vulnerability in joi. A fix is available for joi — see the affected versions and patch details below.
joi: Prototype pollution via a `__proto__` language key in custom messages
Exploitation Status
No confirmed exploitation observed yet
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for CVE-2026-84368.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
CVE-2026-84368 by exploitation likelihood (EPSS) against impact (CVSS). Outside the shaded patch-first corner.
Where this sits among everything scored
Of 395,249 CVEs with a current EPSS score, this one falls in the < 10% band (highlighted). Counts from FIRST.org, log-scaled.
Real-World Exposure
How broadly this vulnerability is actually deployed: weekly install volume shows current usage, and reverse-dependency count shows how many other packages break if it stays unpatched.
joinpm@hapi/joinpmDescription
Impact
An application that passes attacker-controlled data into joi's custom message configuration (messages(), message(), prefs({ messages }), Joi.extend({ messages }) or rule({ message })) lets the attacker write properties onto Object.prototype, where every object in the process then inherits them. A key named __proto__ was treated as a language name, and the code reused the object it found at that key, which resolves to the prototype rather than to a new own property; a key named constructor did the same to the Object function's statics. A consuming application that gates on the mere presence of a property (if (user.isAdmin)) can be made to take the wrong branch for every object it inspects.
This is not reachable from data that joi validates. Custom messages are schema-construction configuration, normally written by the application developer. Exploitation therefore requires an application that feeds untrusted input straight into schema construction.
Patches
Upgrade to version 18.2.5 or 17.13.6.
Workarounds
Do not pass untrusted input into messages(), message(), prefs({ messages }), Joi.extend({ messages }) or rule({ message }). Or validate that they don't contain any __proto__ or constructor property.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 📦npm | joi | ≥ 17.2.0&&< 17.13.6 | 17.13.6npm install joi@17.13.6 |
| 📦npm | @hapi/joi | ≥ 16.0.0 | No fix |
| 📦npm | joi | ≥ 18.0.0&&< 18.2.5 | 18.2.5npm install joi@18.2.5 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for joi, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update joi to 17.13.6 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2026-84368 is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
A flaw was found in joi, a data validation library for JavaScript. Prototype pollution exists in the message compilation and merging logic, where attacker-controlled language keys such as __proto__ supplied through schema configuration methods can write properties onto Object.prototype. Exploitation requires an…
Upgrade to joi 17.13.6 or 18.2.5. As a workaround, ensure that only trusted, developer-controlled input is passed into joi schema configuration methods such as messages(), message(), prefs({ messages }), Joi.extend({ messages }), or rule({ message }). Do not pass user-supplied data directly into schema construction.Source: Red Hat security advisory for CVE-2026-84368 (CC BY 4.0)
Frequently Asked Questions
Is CVE-2026-84368 in your dependencies?
Find it across npm, including transitive dependencies.