CVE-2026-86318
Received Received - Intake

Stack-Based Buffer Overflow in json-patch Java Library

Vulnerability report for CVE-2026-86318, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.

Publication date: 2026-09-07

Last updated on: 2026-09-07

Assigner: VulDB

Description

A flaw has been found in java-json-tools json-patch up to 1.13. Affected is the function JsonMergePatch.fromJson of the file JsonMergePatchDeserializer.java. Executing a manipulation can lead to stack-based buffer overflow. The attack may be performed from remote. The exploit has been published and may be used. The project was informed of the problem early through an issue report but has not responded yet.

CVSS Scores

EPSS Scores

Probability:
Percentile:

Meta Information

Published
2026-09-07
Last Modified
2026-09-07
Generated
2026-09-07
AI Q&A
2026-09-07
EPSS Evaluated
N/A
NVD
EUVD

Affected Vendors & Products

Showing 1 associated CPE
Vendor Product Version / Range
java-json-tools json-patch to 1.13 (inc)

Helpful Resources

Exploitability

CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-119 The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.
CWE-121 A stack-based buffer overflow condition is a condition where the buffer being overwritten is allocated on the stack (i.e., is a local variable or, rarely, a parameter to a function).

Attack-Flow Graph

AI Quick Actions

Instant insights powered by AI
Executive Summary

This vulnerability is a stack-based buffer overflow in the java-json-tools json-patch library up to version 1.13. It occurs in the JsonMergePatchDeserializer.java file during JSON merge patch processing. The flaw allows attackers to cause a stack overflow by sending deeply nested JSON objects, leading to a denial-of-service condition. The issue stems from uncontrolled recursion without depth limits in the deserialization process.

Detection Guidance

To detect this vulnerability, monitor for stack overflow errors in applications using json-patch 1.13. Check logs for StackOverflowError exceptions during JSON Merge Patch operations. Use network traffic analysis tools to identify unusually large or deeply nested JSON payloads (over 2000 levels) sent to endpoints using JsonMergePatch.fromJson().

Commands: 1) grep -r 'StackOverflowError' /var/log/ 2) tcpdump -i any -A -s 0 'tcp port 80 and (((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)' | grep -a '{' 3) Use application performance monitoring tools to track thread pool exhaustion events.

Impact Analysis

This vulnerability can cause denial-of-service by crashing applications using the affected library. Attackers can send a single HTTP request with a ~40KB payload containing deeply nested JSON to trigger a stack overflow. This may exhaust the application's thread pool and disrupt services. The attack requires no authentication and can be performed remotely.

Compliance Impact

This vulnerability could impact compliance with GDPR and HIPAA by enabling denial-of-service attacks that disrupt services handling sensitive data. A stack overflow could crash applications processing JSON Merge Patch requests, potentially leading to service unavailability for systems managing personal or health information.

Mitigation Strategies

Immediately upgrade to a patched version of json-patch that includes recursion depth limits in the deserialize() method. If upgrading is not possible, implement application-level safeguards by adding input validation to reject JSON payloads exceeding a safe nesting depth (e.g., 1000 levels). Temporarily disable endpoints using JsonMergePatch if they are not critical.

Apply network-level protections like WAF rules to block excessively large or deeply nested JSON requests. Monitor for exploitation attempts and restrict access to affected endpoints until mitigation is complete.

Chat Assistant

Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-86318. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70

EPSS Chart