CVE-2026-59952: CWE-755: Improper Handling of Exceptional Conditions in open-circle valibot
Valibot versions prior to 1.4.2 have an improper handling of exceptional conditions vulnerability in the flatten() helper function. When validation issues involve attacker-controlled object keys that collide with inherited Object.prototype properties (such as toString, valueOf, or hasOwnProperty), the flatten() function may throw a TypeError. This occurs because the function attempts to push errors onto an inherited method instead of an error array. The issue affects applications using record() validation combined with flatten() to process validation errors. This vulnerability can cause application crashes during request handling, impacting availability. The issue is fixed in version 1.4.2.
AI Analysis
Technical Summary
Valibot is a data validation library that uses schemas. In versions before 1.4.2, the flatten() helper function can throw a TypeError when validation issues contain keys that are attacker-controlled and collide with Object.prototype properties like toString, valueOf, or hasOwnProperty. The record() validation method filters some dangerous keys (__proto__, prototype, constructor) but still accepts keys that shadow inherited Object.prototype methods. If such keys cause validation errors, flatten() tries to push errors onto a function inherited from Object.prototype instead of an array, causing a TypeError and crashing the application. This is not a prototype pollution vulnerability but an error handling flaw affecting availability. The vulnerability is fixed in version 1.4.2.
Potential Impact
Applications using Valibot versions prior to 1.4.2 that validate user-controlled objects with record() and then flatten validation errors may crash with a TypeError instead of returning structured validation errors. This leads to denial of service or degraded availability during request processing. There is no evidence of code execution or data corruption. The impact is limited to error handling and availability.
Mitigation Recommendations
Upgrade Valibot to version 1.4.2 or later, where this issue is fixed. No other mitigations are documented. Patch status is not explicitly stated in the vendor advisory, but the description confirms the fix in 1.4.2. If upgrading is not immediately possible, avoid passing validation issues containing keys that shadow Object.prototype properties to the flatten() helper.
CVE-2026-59952: CWE-755: Improper Handling of Exceptional Conditions in open-circle valibot
Description
Valibot versions prior to 1.4.2 have an improper handling of exceptional conditions vulnerability in the flatten() helper function. When validation issues involve attacker-controlled object keys that collide with inherited Object.prototype properties (such as toString, valueOf, or hasOwnProperty), the flatten() function may throw a TypeError. This occurs because the function attempts to push errors onto an inherited method instead of an error array. The issue affects applications using record() validation combined with flatten() to process validation errors. This vulnerability can cause application crashes during request handling, impacting availability. The issue is fixed in version 1.4.2.
CVSS v4.0
Score 6.9medium
Affected software
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
Valibot is a data validation library that uses schemas. In versions before 1.4.2, the flatten() helper function can throw a TypeError when validation issues contain keys that are attacker-controlled and collide with Object.prototype properties like toString, valueOf, or hasOwnProperty. The record() validation method filters some dangerous keys (__proto__, prototype, constructor) but still accepts keys that shadow inherited Object.prototype methods. If such keys cause validation errors, flatten() tries to push errors onto a function inherited from Object.prototype instead of an array, causing a TypeError and crashing the application. This is not a prototype pollution vulnerability but an error handling flaw affecting availability. The vulnerability is fixed in version 1.4.2.
Potential Impact
Applications using Valibot versions prior to 1.4.2 that validate user-controlled objects with record() and then flatten validation errors may crash with a TypeError instead of returning structured validation errors. This leads to denial of service or degraded availability during request processing. There is no evidence of code execution or data corruption. The impact is limited to error handling and availability.
Mitigation Recommendations
Upgrade Valibot to version 1.4.2 or later, where this issue is fixed. No other mitigations are documented. Patch status is not explicitly stated in the vendor advisory, but the description confirms the fix in 1.4.2. If upgrading is not immediately possible, avoid passing validation issues containing keys that shadow Object.prototype properties to the flatten() helper.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-07-07T18:49:15.607Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a6aa0b59c2644c7f849c1bf
Added to database: 07/30/2026, 00:54:13 UTC
Last enriched: 07/30/2026, 01:07:54 UTC
Last updated: 07/30/2026, 01:47:07 UTC
Views: 20
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.