Apache bRPC: Stack Exhaustion via Unbounded Recursion in JSON Parser
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Denial of service
- Confidentiality · integrity · availability
- None · None · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CISA ADP. Fix status from CNA. Impact type from CWE-674.
Summary
Uncontrolled recursion in the json2pb component in Apache bRPC (version < 1.15.0) on all platforms allows remote attackers to make the server crash via sending deep recursive json data. Root Cause: The bRPC json2pb component uses rapidjson to parse json data from the network. The rapidjson parser uses a recursive parsing method by default. If the input json has a large depth of recursive structure, the parser function may run into stack overflow. Affected Scenarios: Use bRPC server with protobuf message to serve http+json requests from untrusted network. Or directly use JsonToProtoMessage to convert json from untrusted input. How to Fix: (Choose one of the following options) 1. Upgrade bRPC to version 1.15.0, which fixes this issue. 2. Apply this patch: https://github.com/apache/brpc/pull/3099 Note: No matter which option you choose, you should know that the fix introduces a recursion depth limit with default value 100. It affects these functions: ProtoMessageToJson, ProtoMessageToProtoJson, JsonToProtoMessage, and ProtoJsonToProtoMessage. If your requests contain json or protobuf messages that have a depth exceeding the limit, the request will be failed after applying the fix. You can modify the gflag json2pb_max_recursion_depth to change the limit.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- Yes
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
Remediation
- Fix · CNA Apache bRPC (Apache Software Foundation) Fixed in 1.15.0
Timeline
- 2026-10-02 Threatist record created from CVE-2025-59789
- 2026-10-03 Alias added: GHSA-x4fp-gjpv-c6r5
References
More Apache Brpc vulnerabilities
- TI-2025-37397 Apache bRPC: Remote command injection vulnerability in heap builtin service CVSS 3.1CRITICAL 9.8
- TI-2023-14776 Apache bRPC: ServerOptions.pid_file may cause arbitrary code execution CVSS 3.1CRITICAL 9.8
- TI-2025-34269 Apache bRPC: Redis Parser Remote Denial of Service CVSS 3.1HIGH 7.5
- TI-2024-15499 Apache bRPC: HTTP request smuggling vulnerability CVSS 3.1HIGH 7.5
- TI-2023-24531 Apache bRPC: The builtin service rpcz page has an XSS attack vulnerability CVSS 3.1MEDIUM 6.1
Sources
- CVE-2025-59789 · CVE Program
- CVE-2025-59789 · NVD
- FIRST EPSS
- GHSA-x4fp-gjpv-c6r5 · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences