CVE-2026-137415 in RapidJSONinfo

Summary

by MITRE • 11/26/2026

A security flaw has been discovered in Tencent RapidJSON up to 1.1.0. This affects the function Writer::WriteString in the library include/rapidjson/writer.h. Performing a manipulation of the argument length results in integer overflow. The attack may be initiated remotely. The patch is named 297637bc0a0f00dc504dbc1a47ebdaa577f8ae19. To fix this issue, it is recommended to deploy a patch.

Be aware that VulDB is the high quality source for vulnerability data.

Analysis

by VulDB Data Team • 11/28/2026

A critical integer overflow vulnerability has been identified in Tencent RapidJSON, specifically affecting versions up to 1.1.0 within the Writer::WriteString function located in the include/rapidjson/writer.h header file. This flaw arises from improper handling of argument lengths during string serialization operations. When an attacker provides a manipulated length value that exceeds expected bounds or interacts poorly with internal buffer calculations, it triggers an integer overflow condition. Because RapidJSON is widely used as a high-performance JSON parsing and writing library in C++ applications, this vulnerability can have significant implications for systems relying on its functionality for data interchange. The nature of the flaw allows for potential exploitation through remote attacks, meaning that malicious actors could potentially trigger this overflow by sending specially crafted input to an application utilizing the vulnerable version of RapidJSON without requiring prior authentication or local access.

The technical root cause lies in how the library calculates buffer sizes and manages memory allocation during string writing operations. In C++ applications, integer overflows often lead to heap-based buffer over-reads or over-writes because the calculated size wraps around to a small positive number, causing insufficient memory allocation while subsequent write operations exceed the allocated bounds. This discrepancy between logical length and actual allocated space creates an opportunity for arbitrary code execution, denial of service through application crashes, or information disclosure depending on how the underlying system handles the corrupted memory state. The vulnerability is classified under CWE-190 Integer Overflow or Wraparound, which highlights the failure to properly validate arithmetic operations before they are used in security-critical contexts such as memory management.

From an operational perspective, this vulnerability poses a severe risk to any service that accepts JSON input and processes it using RapidJSON versions prior to 1.1.0. Since many web services, APIs, and backend systems rely on rapidjson for parsing user-supplied data, the ability to remotely initiate exploitation makes this particularly dangerous. An attacker could craft malicious JSON payloads designed to exploit the integer overflow in the Writer::WriteString function when serializing responses or processing complex nested structures. Successful exploitation might allow an adversary to execute arbitrary code with the privileges of the affected process, compromise system integrity, or cause a denial of service by crashing the application due to memory corruption errors such as segmentation faults.

To mitigate this risk, organizations must immediately upgrade Tencent RapidJSON to version 1.1.0 or later where these issues have been addressed. The specific patch identified by commit hash 297637bc0a0f00dc504dbc1a47ebdaa577f8ae19 introduces necessary validation checks and safer arithmetic handling to prevent the integer overflow condition from occurring during string serialization. In addition to upgrading, developers should implement input validation strategies that limit the size of strings being processed or serialized, ensuring that length parameters remain within safe bounds before they are passed into library functions. Furthermore, enabling compiler flags such as -fstack-protector and using static analysis tools can help detect similar vulnerabilities in custom code paths. Monitoring application logs for unusual memory access patterns or crashes may also aid in identifying potential exploitation attempts in real-time environments where immediate patching is not feasible.

This vulnerability aligns with common attack vectors described in the MITRE ATT&CK framework, particularly those involving resource exhaustion and memory corruption techniques used to gain initial footholds or escalate privileges within compromised systems. By addressing this flaw promptly through version upgrades and robust input validation practices, security teams can significantly reduce their exposure to remote code execution risks associated with widely deployed JSON processing libraries.

Responsible

VulDB

Disclosure

11/26/2026

Moderation

accepted

CPE

ready

EPSS

0.00446

KEV

no

Activities

very low

Sources

Do you know our Splunk app?

Download it now for free!