CVE-2026-9334: CWE-843 Access of Resource Using Incompatible Type ('Type Confusion') in RURBAN Cpanel::JSON::XS
Cpanel::JSON::XS versions before 4.41 for Perl allow type confusion via duplicate object keys when dupkeys_as_arrayref is enabled.decode_hv() collapses duplicate object keys into an array reference under dupkeys_as_arrayref. The branch reached for a duplicate key tests `SvTYPE (old_value) != SVt_RV && SvTYPE (SvRV (old_value)) != SVt_PVAV`, which evaluates SvRV(old_value) before establishing that old_value is a reference. When the existing value is a plain scalar rather than an array reference, a non-reference scalar is dereferenced as a reference. A caller decoding untrusted JSON with dupkeys_as_arrayref enabled is crashed, and the incompatible access follows a pointer taken from attacker controlled scalar contents.
AI Analysis
Technical Summary
CVE-2026-9334 affects Cpanel::JSON::XS versions prior to 4.41. When the dupkeys_as_arrayref option is enabled, the decode_hv() function collapses duplicate JSON object keys into an array reference. However, the code incorrectly evaluates SvRV(old_value) before confirming old_value is a reference, causing a type confusion. This results in dereferencing a non-reference scalar as a reference, which can crash the caller decoding untrusted JSON and lead to incompatible memory access based on attacker-controlled data.
Potential Impact
An attacker supplying crafted JSON with duplicate keys can cause the decoder to crash due to type confusion. This may lead to denial of service and potentially memory corruption or other undefined behavior due to dereferencing invalid pointers derived from attacker-controlled scalar contents. The CVSS score of 7.3 indicates high severity with network attack vector, no privileges required, and impacts confidentiality, integrity, and availability.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Users should avoid enabling dupkeys_as_arrayref when decoding untrusted JSON until an official fix is available. Monitor vendor channels for updates and apply any official patches once released.
CVE-2026-9334: CWE-843 Access of Resource Using Incompatible Type ('Type Confusion') in RURBAN Cpanel::JSON::XS
Description
Cpanel::JSON::XS versions before 4.41 for Perl allow type confusion via duplicate object keys when dupkeys_as_arrayref is enabled.decode_hv() collapses duplicate object keys into an array reference under dupkeys_as_arrayref. The branch reached for a duplicate key tests `SvTYPE (old_value) != SVt_RV && SvTYPE (SvRV (old_value)) != SVt_PVAV`, which evaluates SvRV(old_value) before establishing that old_value is a reference. When the existing value is a plain scalar rather than an array reference, a non-reference scalar is dereferenced as a reference. A caller decoding untrusted JSON with dupkeys_as_arrayref enabled is crashed, and the incompatible access follows a pointer taken from attacker controlled scalar contents.
CVSS v3.1
Score 7.3high
Affected software
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
CVE-2026-9334 affects Cpanel::JSON::XS versions prior to 4.41. When the dupkeys_as_arrayref option is enabled, the decode_hv() function collapses duplicate JSON object keys into an array reference. However, the code incorrectly evaluates SvRV(old_value) before confirming old_value is a reference, causing a type confusion. This results in dereferencing a non-reference scalar as a reference, which can crash the caller decoding untrusted JSON and lead to incompatible memory access based on attacker-controlled data.
Potential Impact
An attacker supplying crafted JSON with duplicate keys can cause the decoder to crash due to type confusion. This may lead to denial of service and potentially memory corruption or other undefined behavior due to dereferencing invalid pointers derived from attacker-controlled scalar contents. The CVSS score of 7.3 indicates high severity with network attack vector, no privileges required, and impacts confidentiality, integrity, and availability.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Users should avoid enabling dupkeys_as_arrayref when decoding untrusted JSON until an official fix is available. Monitor vendor channels for updates and apply any official patches once released.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- CPANSec
- Date Reserved
- 2026-05-22T23:33:44.954Z
- Cvss Version
- null
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a1f765ee29bf47b50276b24
Added to database: 06/03/2026, 00:33:34 UTC
Last enriched: 06/10/2026, 11:05:59 UTC
Last updated: 07/31/2026, 19:23:00 UTC
Views: 160
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.