You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "Aias00 (via GitHub)" <gi...@apache.org> on 2026/08/03 13:31:43 UTC
[I] [Bug] Proxy remoting heartbeat should reject empty request bodies [rocketmq]
Aias00 opened a new issue, #10791:
URL: https://github.com/apache/rocketmq/issues/10791
### What happened?
`ClientManagerActivity.heartBeat` decodes the remoting request body with `HeartbeatData.decode(request.getBody(), HeartbeatData.class)` and immediately dereferences the result. `RemotingSerializable.decode` returns `null` for a null body, so a malformed `HEART_BEAT` request without a body can hit a `NullPointerException` and be reported as an internal proxy error.
### Why this matters
The Proxy client-management path is part of the Studio/Proxy Admin foundation. Malformed client heartbeat frames should be rejected with a clear response code and remark instead of surfacing as an internal exception.
### Expected behavior
Proxy should return a deterministic `INVALID_PARAMETER` response for empty or undecodable heartbeat bodies and must not register producer or consumer channels for that request.
### Scope
RocketMQ Studio track 2 / Proxy client management hardening.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Bug] Proxy remoting heartbeat should reject empty request bodies [rocketmq]
Posted by "RockteMQ-AI (via GitHub)" <gi...@apache.org>.
RockteMQ-AI commented on issue #10791:
URL: https://github.com/apache/rocketmq/issues/10791#issuecomment-5192793553
**Issue Evaluation**
Category: `type/bug` | Status: **Confirmed**
The reported issue has been verified against the current codebase.
**Root Cause:** `ClientManagerActivity.heartBeat()` (line 80) calls `HeartbeatData.decode(request.getBody(), HeartbeatData.class)` and immediately dereferences the result at line 81 (`heartbeatData.getClientID()`) without a null check. `RemotingSerializable.decode()` returns `null` when the input body is `null`, so a malformed `HEART_BEAT` request with an empty or null body triggers a `NullPointerException` that surfaces as an internal proxy error.
**Impact:** Proxy client-management path (`module/proxy`, `module/remoting`). Any client or tool that sends a malformed heartbeat frame can cause an unhandled exception in the proxy.
**Severity:** Medium — does not crash the proxy, but produces misleading internal error responses and may leak stack trace details.
**Suggested Fix:** Add a null check on the decoded `HeartbeatData` before dereferencing. Return a deterministic `INVALID_PARAMETER` response code with a clear remark when the body is null or undecodable.
An automated fix proposal may be generated. Reply `/approve` to proceed with PR generation.
---
*Automated evaluation by RockteMQ-AI*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Bug] Proxy remoting heartbeat should reject empty request bodies [rocketmq]
Posted by "RockteMQ-AI (via GitHub)" <gi...@apache.org>.
RockteMQ-AI commented on issue #10791:
URL: https://github.com/apache/rocketmq/issues/10791#issuecomment-5244919900
**Feedback Timeout**\n\nNo feedback was received within 72 hours. The automated fix proposal has been closed.\n\nIf you'd like to proceed with a fix, please reply to this issue and a maintainer will review it.\n\n---\n*Automated timeout by RockteMQ-AI*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] [Bug] Proxy remoting heartbeat should reject empty request bodies [rocketmq]
Posted by "Aias00 (via GitHub) via commits" <co...@rocketmq.apache.org>.
Aias00 closed issue #10791: [Bug] Proxy remoting heartbeat should reject empty request bodies
URL: https://github.com/apache/rocketmq/issues/10791
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@rocketmq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org