Skip to main content

cJSON CVE-2026-67217

| EUVDEUVD-2026-50329 MEDIUM
Incorrect Behavior Order (CWE-696)
2026-07-29 VulnCheck GHSA-pr46-97qf-f32c
6.9
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Supply crafted patch document via network or file input
  2. Delivery
    Embed replace operation with missing value member or move with unresolvable destination
  3. Exploit
    apply_patch() detaches and frees target node before completing validation
  4. Execution
    API returns failure status with document already mutated
  5. Impact
    Application error handler executes while relying on now-corrupt document state

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Incorrect behavior order
Exploitation Conditions

The attacker must control the patch document - a JSON array of RFC 6902 operations - supplied to cJSONUtils_ApplyPatches() or cJSONUtils_ApplyPatchesCaseSensitive(). This requires the application to expose an interface (network API endpoint, file or IPC channel) that accepts externally-controlled patch input without fully sanitizing operation structure before passing it to the cJSON API. The two specific triggering conditions are: (1) a replace operation object where the value key is absent, or (2) a move operation where the to path cannot be resolved in the current target document. Exploitation is limited entirely to the in-memory integrity of the target JSON document - there is no code execution, memory safety violation, or confidentiality breach. Applications that treat any cJSONUtils_ApplyPatches() failure return as a signal to immediately discard and re-initialize the entire target document object sidestep the silent-corruption impact, as do applications that restrict patch input to operation types other than replace and move.

Impact

The CVSS 4.0 base score of 6.9 (Medium) reflects broad network accessibility with no required privileges or user interaction (AV:N/AC:L/AT:N/PR:N/UI:N), but the realized impact is bounded to a low integrity violation on the vulnerable system (VI:L) with no confidentiality or availability impact recorded. KEV status is not confirmed and no weaponized exploit has been identified; a researcher blog post at joshua.hu and a direct GitHub source reference are publicly available, which may accelerate exploit development but do not constitute confirmed active exploitation. EPSS data was not provided in the source intelligence, so exploitation probability cannot be quantified. Practical risk is highly application-dependent: the vulnerability is meaningful only where the calling application exposes an interface that accepts attacker-controlled patch documents and relies on cJSONUtils_ApplyPatches() failure status to gate document commits. In IoT firmware, configuration management services, or device state engines where the target document represents authoritative state, silent partial corruption could produce disproportionate operational impact relative to the CVSS VI:L rating. The 'Information Disclosure' tag in source intelligence appears inconsistent with the described integrity-only impact and may reflect a tagging error or an undocumented secondary effect not present in the primary description.

Exploit ScenarioDerived

An attacker with the ability to supply a crafted JSON Patch document to a network-facing application built on cJSON submits a replace operation targeting a sensitive configuration key but omits the required value member; apply_patch() deletes the existing key from the document before detecting the missing value and returns an error, but the target document is now permanently missing that key - silently degrading application state even as the caller's error handler executes and believes the patch was rejected. A detailed researcher write-up and direct source code reference are publicly available at joshua.hu and GitHub, which may facilitate exploit development by any party examining the affected code path.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
No patch listed yet 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 29, 2026

Non-atomic JSON Patch application in cJSON through 1.7.19 allows an attacker who controls the patch document to silently corrupt the target JSON structure even when the API returns a failure status. The apply_patch() function in cJSON_Utils.c deletes existing target members before completing operation validation, meaning a malformed replace (missing value) or move (unresolvable destination) permanently destroys data from the in-memory document tree - defeating the RFC 6902 all-or-nothing contract that callers rely on to reject bad patches safely. No public exploit has been identified at time of analysis, but a detailed researcher disclosure and direct source code reference are publicly available, which may lower the barrier to exploitation; KEV status is not confirmed.

RemediationAI

No vendor-released patch has been identified at time of analysis; the most recent confirmed-affected version is 1.7.19. Operators should monitor the upstream repository at https://github.com/DaveGamble/cJSON for a patched release and upgrade immediately upon availability. As a compensating control, applications that require atomic patch semantics should deep-copy the target cJSON object before invoking cJSONUtils_ApplyPatches() and restore from that copy on any non-success return - this trades a memory allocation per patch call for correctness guarantees and is the most robust workaround. Alternatively, pre-validate patch documents before submission by rejecting any operation array that contains a replace without a value member or a move whose to path does not exist in the current document; this adds per-call validation logic but eliminates the vulnerable deletion-before-validation sequence. Where patch input originates from untrusted external sources, restricting permitted operation types to add and remove (which do not trigger the affected code paths) eliminates exposure at the cost of reduced RFC 6902 coverage. See the VulnCheck advisory for additional context.

Affected VersionsENISA

cJSON 0 ≤1.7.19

Affected Packages

euvd cjson no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

cJSON is a lightweight, open-source JSON library written in C, maintained by Dave Gamble (CPE: cpe:2.3:a:davegamble:cjson). The affected functionality implements RFC 6902 JSON Patch operations via apply_patch() in cJSON_Utils.c (lines 887-948 of the v1.7.19 source). CWE-696 (Incorrect Behavior Order) precisely describes the root cause: the library detaches and frees the existing target node from the document tree before validating that the replacement value is present or that the move destination path is resolvable. RFC 6902 mandates atomic semantics - all patch operations succeed together or the document is left unchanged. cJSON violates this invariant by sequencing deletion ahead of validation, producing irreversible in-memory mutations even when the function ultimately signals failure. Both cJSONUtils_ApplyPatches() and cJSONUtils_ApplyPatchesCaseSensitive() are affected entry points.

Know when Cjson gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 6.9 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N
vuln.today AI 5.3 MEDIUM

Network vector reflects library use in network-facing services; no privilege required to supply a patch document; scope unchanged and impact limited to low integrity loss with no confidentiality or availability effect.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N
SUSE 5.3 MEDIUM
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
Red Hat 5.3 MEDIUM

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
Low
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

DescriptionCVE.org

cJSON through 1.7.19 applies RFC 6902 JSON Patch operations non-atomically in apply_patch() in cJSON_Utils.c. For a replace operation that is missing its value member, or a move operation whose destination path cannot be resolved, the existing target member is detached and deleted before the operation is fully validated, so the target document is mutated while cJSONUtils_ApplyPatches() or cJSONUtils_ApplyPatchesCaseSensitive() returns a failure status. An attacker who can supply the patch document can destroy addressable members of the target document even though the API reports that the patch failed, defeating the all-or-nothing behavior callers rely on to reject bad patches.

Threat Intelligence Overview

EPSS Score
0.2%
Top 86% exploitable
Prevalence
High
widely used lightweight C JSON library in embedded, IoT, and firmware projects
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment Vendor GitHub

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.2%
Patch available No
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Out-of-Cycle
Exploitation
Poc
System Exposure· derived
Open
Automatable
Yes
Human Impact· derived
High
Technical Impact
Partial

Priority Score

34
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +34
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

More in Cjson

View all
CVE-2025-57052 CRITICAL POC
9.8 Sep 03

cJSON 1.5.0 through 1.7.18 allows out-of-bounds access via the decode_array_index_from_pointer function in cJSON_Utils.c

CVE-2019-11835 CRITICAL POC
9.8 May 09

cJSON before 1.7.11 allows out-of-bounds access, related to multiline comments. Rated critical severity (CVSS 9.8), this

CVE-2019-11834 CRITICAL POC
9.8 May 09

cJSON before 1.7.11 allows out-of-bounds access, related to \x00 in a string literal. Rated critical severity (CVSS 9.8)

CVE-2018-1000217 CRITICAL POC
9.8 Aug 20

Dave Gamble cJSON version 1.7.3 and earlier contains a CWE-416: Use After Free vulnerability in cJSON library that can r

CVE-2018-1000216 HIGH POC
8.8 Aug 20

Dave Gamble cJSON version 1.7.2 and earlier contains a CWE-415: Double Free vulnerability in cJSON library that can resu

CVE-2024-31755 HIGH POC
7.6 Apr 26

cJSON v1.7.17 was discovered to contain a segmentation violation, which can trigger through the second parameter of func

CVE-2023-50472 HIGH POC
7.5 Dec 14

cJSON v1.7.16 was discovered to contain a segmentation violation via the function cJSON_SetValuestring at cJSON.c. Rated

CVE-2023-50471 HIGH POC
7.5 Dec 14

cJSON v1.7.16 was discovered to contain a segmentation violation via the function cJSON_InsertItemInArray at cJSON.c. Ra

CVE-2019-1010239 HIGH POC
7.5 Jul 19

DaveGamble/cJSON cJSON 1.7.8 is affected by: Improper Check for Unusual or Exceptional Conditions. Rated high severity (

CVE-2026-87933 MEDIUM POC
5.5 Sep 10

Heap use-after-free in DaveGamble cJSON's cJSONUtils_MergePatch function (cJSON_Utils.c) affects all versions through 1.

CVE-2026-67215 HIGH
8.7 Jul 29

Denial of service in cJSON (DaveGamble's C JSON parser) through version 1.7.19 lets a remote attacker crash any applicat

CVE-2026-67216 HIGH
8.2 Jul 29

Denial of service in the cJSON C library (versions through 1.7.19) arises from exponential algorithmic complexity in the

Vendor StatusVendor

SUSE

Severity: Moderate
Product Status
SUSE Linux Enterprise Desktop 15 SP7 Affected
SUSE Linux Enterprise Server 15 SP7 Affected
SUSE Linux Enterprise Server 16.0 Affected
SUSE Linux Enterprise Server 16.1 Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP7 Affected

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy