ShadowySpirits commented on code in PR #5029:
URL: https://github.com/apache/rocketmq/pull/5029#discussion_r967574188
##########
remoting/src/main/java/org/apache/rocketmq/remoting/netty/NettyDecoder.java:
##########
@@ -45,6 +46,14 @@ public Object decode(ChannelHandlerContext ctx, ByteBuf in)
throws Exception {
}
return RemotingCommand.decode(frame);
} catch (Exception e) {
+ in.resetReaderIndex();
Review Comment:
> > Under normal circumstances, there will not be many malformed frames. So
this feature has almost no impact on performance. If there are a lot of
malformed frames, it may be a packet flood attack. We should ban attacker ip.
> > @zhouxinyu do you have any better suggestions?
>
> How about use RMQ admin CL? @ShadowySpirits
This tool is designed for application developers who use rocketmq sdk. They
may not have experience using mqadmin, even if their runtime doesn't have jdk.
So I hope to be able to use linux built-in software to achieve this function.
@mxsm
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]