제출 #1064065: Tencent RapidJSON 1.1.0 Memory Corruption정보

제목Tencent RapidJSON 1.1.0 Memory Corruption
설명A critical vulnerability has been identified in Tencent RapidJSON through version 1.1.0 and git master (commit 24b5e7a). The vulnerability affects the function Writer::WriteString located in include/rapidjson/writer.h (lines 397-402). When reserving memory for string serialization, the reservation calculation: PutReserve(*os_, 2 + length * 12); is evaluated using 32-bit unsigned arithmetic (SizeType). For string lengths of 357,913,942 characters or more, this multiplication wraps modulo 2^32, requesting only 10 bytes of buffer reservation while the default buffer capacity is 256 bytes. In production builds and downstream distribution packages compiled with -DNDEBUG, Stack::PushUnsafe assertions are compiled out. The writer then copies over 357 MB of string data into the 256-byte buffer without bounds checking. This leads to an extensive heap buffer overflow that allows an attacker to corrupt adjacent memory and hijack control flow to achieve arbitrary code execution. The underlying integer overflow was noted in upstream issues #2336 and #2348 as a denial of service / assertion crash, and fix pull request #2396 was closed unmerged on 2026-10-05. The escalation to arbitrary code execution in release builds is newly identified. Remediation requires widening length to size_t: PutReserve(*os_, 2 + static_cast<size_t>(length) * 12); Coordinated disclosure is underway with CERT/CC (Tracking ID: VRF#26-10-WMJBQ).
원천⚠️ https://github.com/Tencent/rapidjson/issues/2336
사용자 0xtoxic (UID 102605)
제출2026. 10. 29. AM 07:48 (28 날 ago)
모더레이션2026. 11. 26. AM 10:06 (28 days later)
상태수락
VulDB 항목444244 [Tencent RapidJSON 까지 1.1.0 writer.h Writer::WriteString length 메모리 손상]
포인트들20

Do you want to use VulDB in your project?

Use the official API to access entries easily!