Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-95117 Overview
CVE-2026-95117 is a buffer overflow vulnerability in the zserge/jsmn JSON parser at HEAD commit 25647e6. The flaw affects the jsmn.h header, the jsmn_parse() function, and the dump() routine in example/jsondump.c. A remote attacker can trigger the overflow by submitting crafted JSON input to applications that embed the library, resulting in denial of service. The jsmn library is a minimalistic, single-header JSON parser written in C and widely used in embedded systems and IoT firmware, which broadens the potential exposure footprint.
Critical Impact
Remote attackers can crash applications parsing untrusted JSON through the vulnerable jsmn_parse() path, disrupting availability of services that depend on the library.
Affected Products
- zserge jsmn at HEAD commit 25647e6
- Applications statically linking the vulnerable jsmn.h single-header parser
- Example tooling shipped with the project, including example/jsondump.c
Discovery Timeline
- 2026-10-13 - CVE-2026-95117 published to the National Vulnerability Database (NVD)
- 2026-10-13 - Last updated in NVD database
Technical Details for CVE-2026-95117
Vulnerability Analysis
The vulnerability resides in jsmn_parse(), the core tokenization routine in the jsmn.h single-header library. When processing certain malformed or boundary-condition JSON inputs, the parser writes beyond the bounds of its token buffer. The reference example dump() function in example/jsondump.c demonstrates the condition because it iterates tokens produced by jsmn_parse() without additional validation. Because jsmn is distributed as a header-only library, every consuming binary carries its own copy of the vulnerable code, and remediation requires rebuilding each dependent project.
Root Cause
The root cause is insufficient boundary checking during token allocation and traversal inside jsmn_parse(). The parser does not correctly reconcile the number of parsed tokens against the caller-supplied token array size for all input shapes, leading to an out-of-bounds write classified under the Buffer Overflow family [CWE-120].
Attack Vector
An attacker delivers a crafted JSON payload to any application or service that calls jsmn_parse() on attacker-controlled input. This includes network-facing services, embedded HTTP endpoints, and command-line utilities such as the jsondump example. Successful exploitation corrupts adjacent memory and typically causes the process to abort, producing a denial-of-service condition.
No verified public exploit code is available at the time of publication. See the GitHub Issue #249 Discussion and the GitHub Gist Code Snippet for the reporter's reproducer.
Detection Methods for CVE-2026-95117
Indicators of Compromise
- Unexpected SIGSEGV or SIGABRT termination of processes that parse JSON using jsmn
- Core dumps whose stack frames reference jsmn_parse or the example dump function
- Repeated malformed JSON payloads sent to services that embed the parser
Detection Strategies
- Scan source trees and build artifacts for the jsmn.h header at commit 25647e6 or earlier
- Deploy runtime sanitizers such as AddressSanitizer in test environments to surface the out-of-bounds write when fuzzing JSON inputs
- Instrument services with crash-reporting telemetry to detect sudden parser aborts correlated with inbound JSON traffic
Monitoring Recommendations
- Monitor application logs for abnormal exits from JSON ingestion endpoints
- Track EDR telemetry for repeated process crashes on hosts running affected binaries
- Alert on inbound HTTP or MQTT payloads with oversized or deeply nested JSON structures reaching services that embed jsmn
How to Mitigate CVE-2026-95117
Immediate Actions Required
- Inventory applications that bundle jsmn.h and identify those exposed to untrusted JSON input
- Apply the fix proposed in the upstream pull request and rebuild affected binaries
- Place a reverse proxy or input validation layer in front of exposed services to reject malformed JSON payloads
Patch Information
The fix is tracked in the upstream repository. Review the GitHub Pull Request #250 and the specific Pull Request Changes that strengthen bounds handling in jsmn_parse(). Rebuild every binary that statically embeds the header after applying the change.
Workarounds
- Enforce strict size, depth, and token-count limits on JSON input before it reaches jsmn_parse()
- Pre-validate inbound JSON with a hardened parser at the application boundary
- Restrict exposure of services that call the vulnerable parser to trusted network segments until patched
# Locate vulnerable jsmn.h copies across a build tree
find . -name 'jsmn.h' -exec grep -l '25647e6\|JSMN_VERSION' {} \;
# Rebuild dependent projects after pulling the patched header
git -C third_party/jsmn pull origin master
make clean && make
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

