Uncontrolled Recursion DoS in Apache bRPC json2pb
CVE-2025-59789 is an uncontrolled recursion vulnerability in the json2pb component of Apache bRPC affecting versions prior to 1.15.0. The issue arises because json2pb uses RapidJSON to parse JSON input, and RapidJSON's default parsing behavior is recursive. When a bRPC server or application processes attacker-supplied JSON containing excessively deep nested structures, the recursive parser can exhaust the process stack and crash. The vulnerable scenarios described are bRPC servers using protobuf messages to serve HTTP+JSON requests from untrusted networks, and applications that directly call JsonToProtoMessage on untrusted input. The fix introduces a recursion depth limit, defaulting to 100, and applies to ProtoMessageToJson, ProtoMessageToProtoJson, JsonToProtoMessage, and ProtoJsonToProtoMessage.
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
What an attacker gets, and what they’ve been doing with it.
A remote attacker can trigger stack exhaustion and crash the affected server or process by sending deeply nested recursive JSON data. Based on the provided information, the impact is denial of service rather than code execution: the target becomes unavailable or the request-handling process terminates when the parser overflows the stack.
If you can’t patch tonight, do this now.
Until the fix is deployed, reduce exposure by preventing untrusted clients from sending arbitrary deep JSON payloads to affected bRPC HTTP+JSON endpoints, especially those converting JSON into protobuf messages. Where possible, place affected services behind input validation, schema enforcement, request filtering, API gateways, or WAF controls that reject excessively nested JSON. Restrict network access to trusted clients only. For deployments that must accept nested data, monitor for crashes and anomalous requests indicative of deep-recursion payloads. After patching, tune json2pb_max_recursion_depth to a safe value appropriate for expected message structures.
Patch, then assume compromise.
Upgrade Apache bRPC to version 1.15.0 or later, which includes the fix for CVE-2025-59789. If an upgrade is not immediately possible, apply the patch referenced in Apache bRPC pull request #3099. The fix adds a recursion depth limit with a default value of 100. After remediation, review application behavior for legitimate JSON or protobuf payloads with nesting deeper than the configured limit, and adjust the json2pb_max_recursion_depth gflag if operationally necessary.
No public exploits tracked yet. Mallory keeps watching.
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
9 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.