apache / apache/rocketmq

[Bug] 5.x broker开启acl时,控台上重新发送消息错误

Open
#9,393 5 comments 1 reaction 0 assignees View on GitHub
Dominant language
Java
Stars
22.6k
Forks
12k
Avg merge
2d 20h
Merged PRs (30d)
26

Description

### Before Creating the Bug Report

- [x] I found a bug, not just asking a question, which should be created in [GitHub Discussions](https://github.com/apache/rocketmq/discussions).

- [x] I have searched the [GitHub Issues](https://github.com/apache/rocketmq/issues) and [GitHub Discussions](https://github.com/apache/rocketmq/discussions) of this repository and believe that this is not a duplicate.

- [x] I have confirmed that this bug belongs to the current repository, not other repositories of RocketMQ.

### Runtime platform environment

Windows 11

### RocketMQ version

5.2.0

### JDK Version

_No response_

### Describe the Bug

![Image](https://github.com/user-attachments/assets/caa4be5c-7227-4e3e-bb99-77c59cde7970)

### Steps to Reproduce

1.broker开启acl(acl1.0,不是新推出的2.0)
2.启动消费者,用dashboard发送一条消息并消费
3.在dashboard将消息查询出来后点击重新发送

### What Did You Expect to See?

重新发送成功

### What Did You See Instead?

org.apache.rocketmq.client.exception.MQClientException: CODE: 1 DESC: invoke consumer <10.208.62.32@102914> Exception: org.apache.rocketmq.acl.common.AclException: Check signature failed for accessKey=admin_user, org.apache.rocketmq.acl.plain.PlainPermissionManager.validate(PlainPermissionManager.java:629) For more information, please visit the url, https://rocketmq.apache.org/docs/bestPractice/06FAQ

### Additional Context
从broker端debug看是因为broker将消息发送给客户端时又重新调用了acl初始化的`RPCHook`的`doBeforeRequest`

![Image](https://github.com/user-attachments/assets/e1716bea-397a-4c08-b3e4-8437756af480)

但实际上将请求发送出去不用再验证自己发送的请求了

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.