You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by "SummCoder (via GitHub)" <gi...@apache.org> on 2026/06/13 06:55:39 UTC
[PR] [Doc] Update ACL documentation to include required 5.x properties [rocketmq]
SummCoder opened a new pull request, #10499:
URL: https://github.com/apache/rocketmq/pull/10499
### Which Issue(s) This PR Fixes
Fixes #10498
### Brief Description
The current ACL documentation (both English and Chinese) only lists
`aclEnable=true` as the required broker property. In RocketMQ 5.x,
this is insufficient — the new authentication/authorization framework
introduced in 5.x requires five additional properties to function.
Code evidence for each property:
| Property | Source | Effect when omitted |
|----------|--------|---------------------|
| authenticationEnabled | AbstractAuthenticationStrategy.java:54 | Authentication is skipped entirely |
| authorizationEnabled | AbstractAuthorizationStrategy.java:54 | Authorization is skipped entirely |
| migrateAuthFromV1Enabled | AuthMigrator.java:72 | plain_acl.yml is not loaded |
| authenticationMetadataProvider | AuthenticationFactory.java:80-81 | Returns null → "authenticationMetadataProvider is not configured" |
| authorizationMetadataProvider | AuthorizationFactory (same pattern) | Same as above for authorization |
Without these, users experience either:
- ACL silently allowing all traffic (authentication/authorization skipped), or
- "authenticationMetadataProvider is not configured" error on startup
### How Did You Test This Change?
1. Built the project with `mvn -Prelease-all -DskipTests clean install -U`
2. Deployed a fresh RocketMQ 5.5.0 broker with the complete property set
3. Verified ACL authentication works: valid credentials accepted,
invalid credentials correctly rejected with "User not found"
4. Verified mqadmin commands work with default `tools.yml` credentials
matching the ACL account
5. Confirmed omission of any single property causes the documented
failure mode (silent bypass or configuration error)
--
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: [PR] [ISSUE #10498] Update ACL documentation to include required 5.x properties [rocketmq]
Posted by "majialoong (via GitHub)" <gi...@apache.org>.
majialoong commented on code in PR #10499:
URL: https://github.com/apache/rocketmq/pull/10499#discussion_r3413684591
##########
docs/cn/acl/user_guide.md:
##########
@@ -48,6 +49,12 @@ storePathCommitLog=/data/rocketmq/commitlog-a-m
autoCreateSubscriptionGroup=true
## if acl is open,the flag will be true
aclEnable=true
+## RocketMQ 5.x 需要额外配置以下ACL属性
+authenticationEnabled=true
+authorizationEnabled=true
+migrateAuthFromV1Enabled=true
Review Comment:
I think `migrateAuthFromV1Enabled` is not necessary here, since it is only required when migrating from ACL v1 to ACL v2.
##########
docs/cn/acl/user_guide.md:
##########
@@ -48,6 +49,12 @@ storePathCommitLog=/data/rocketmq/commitlog-a-m
autoCreateSubscriptionGroup=true
## if acl is open,the flag will be true
aclEnable=true
+## RocketMQ 5.x 需要额外配置以下ACL属性
+authenticationEnabled=true
+authorizationEnabled=true
+migrateAuthFromV1Enabled=true
+authenticationMetadataProvider=org.apache.rocketmq.auth.authentication.provider.LocalAuthenticationMetadataProvider
+authorizationMetadataProvider=org.apache.rocketmq.auth.authorization.provider.LocalAuthorizationMetadataProvider
listenPort=10911
Review Comment:
Maybe we should also add the default authentication and authorization providers here for completeness:
```
authenticationProvider=org.apache.rocketmq.auth.authentication.provider.DefaultAuthenticationProvider
authorizationProvider=org.apache.rocketmq.auth.authorization.provider.DefaultAuthorizationProvider
```
##########
docs/en/acl/Operations_ACL.md:
##########
@@ -47,6 +48,12 @@ storePathCommitLog=/data/rocketmq/commitlog-a-m
autoCreateSubscriptionGroup=true
## if acl is open,the flag will be true
aclEnable=true
+## RocketMQ 5.x requires the following additional ACL properties
+authenticationEnabled=true
+authorizationEnabled=true
+migrateAuthFromV1Enabled=true
Review Comment:
ditto.
--
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: [PR] [ISSUE #10498] Update ACL documentation to include required 5.x properties [rocketmq]
Posted by "SummCoder (via GitHub)" <gi...@apache.org>.
SummCoder commented on PR #10499:
URL: https://github.com/apache/rocketmq/pull/10499#issuecomment-4747561940
Updated to match the official ACL 2.0 configuration:
- Replaced aclEnable with initAuthenticationUser
- Removed migrateAuthFromV1Enabled (migration-specific, not baseline)
- Added innerClientAuthenticationCredentials
Verified on a clean 5.5.0 deployment — mqadmin and producer both
work correctly with the documented credentials.
--
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: [PR] [ISSUE #10498] Update ACL documentation to include required 5.x properties [rocketmq]
Posted by "RongtongJin (via GitHub)" <gi...@apache.org>.
RongtongJin commented on code in PR #10499:
URL: https://github.com/apache/rocketmq/pull/10499#discussion_r3434178199
##########
docs/cn/acl/user_guide.md:
##########
@@ -48,6 +49,12 @@ storePathCommitLog=/data/rocketmq/commitlog-a-m
autoCreateSubscriptionGroup=true
## if acl is open,the flag will be true
aclEnable=true
+## RocketMQ 5.x 需要额外配置以下ACL属性
+authenticationEnabled=true
+authorizationEnabled=true
+migrateAuthFromV1Enabled=true
Review Comment:
I do not think `migrateAuthFromV1Enabled=true` should be documented as part of the baseline 5.x ACL setup. It is specifically for migrating v1 `plain_acl.yml` data into the new auth model. Please move it into a migration note instead of the default configuration block.
##########
docs/cn/acl/user_guide.md:
##########
@@ -48,6 +49,12 @@ storePathCommitLog=/data/rocketmq/commitlog-a-m
autoCreateSubscriptionGroup=true
## if acl is open,the flag will be true
aclEnable=true
+## RocketMQ 5.x 需要额外配置以下ACL属性
+authenticationEnabled=true
+authorizationEnabled=true
+migrateAuthFromV1Enabled=true
+authenticationMetadataProvider=org.apache.rocketmq.auth.authentication.provider.LocalAuthenticationMetadataProvider
+authorizationMetadataProvider=org.apache.rocketmq.auth.authorization.provider.LocalAuthorizationMetadataProvider
listenPort=10911
Review Comment:
Since the default authentication/authorization providers are part of the effective setup, please document them explicitly or explain that they are defaulted by code. Otherwise users may copy an incomplete config and still be unclear about the provider chain.
##########
docs/en/acl/Operations_ACL.md:
##########
@@ -47,6 +48,12 @@ storePathCommitLog=/data/rocketmq/commitlog-a-m
autoCreateSubscriptionGroup=true
## if acl is open,the flag will be true
aclEnable=true
+## RocketMQ 5.x requires the following additional ACL properties
+authenticationEnabled=true
+authorizationEnabled=true
+migrateAuthFromV1Enabled=true
Review Comment:
Same issue as the Chinese doc: `migrateAuthFromV1Enabled=true` should not be presented as a general required setting. Please document it only for v1 ACL migration scenarios.
--
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: [PR] [Doc] Update ACL documentation to include required 5.x properties [rocketmq]
Posted by "codecov-commenter (via GitHub)" <gi...@apache.org>.
codecov-commenter commented on PR #10499:
URL: https://github.com/apache/rocketmq/pull/10499#issuecomment-4705078626
## [Codecov](https://app.codecov.io/gh/apache/rocketmq/pull/10499?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
:white_check_mark: All modified and coverable lines are covered by tests.
:white_check_mark: Project coverage is 48.05%. Comparing base ([`91cb333`](https://app.codecov.io/gh/apache/rocketmq/commit/91cb333716018d477782754e997bf2232327c97a?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`f41e0cc`](https://app.codecov.io/gh/apache/rocketmq/commit/f41e0cc0e790c0f3de25307befa759665a3f7be0?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
:warning: Report is 5 commits behind head on develop.
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## develop #10499 +/- ##
=============================================
- Coverage 48.13% 48.05% -0.08%
+ Complexity 13355 13330 -25
=============================================
Files 1377 1377
Lines 100707 100707
Branches 13010 13010
=============================================
- Hits 48477 48399 -78
- Misses 46296 46365 +69
- Partials 5934 5943 +9
```
</details>
[:umbrella: View full report in Codecov by Harness](https://app.codecov.io/gh/apache/rocketmq/pull/10499?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
</details>
--
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: [PR] [ISSUE #10498] Update ACL documentation to include required 5.x properties [rocketmq]
Posted by "SummCoder (via GitHub) via commits" <co...@rocketmq.apache.org>.
SummCoder closed pull request #10499: [ISSUE #10498] Update ACL documentation to include required 5.x properties
URL: https://github.com/apache/rocketmq/pull/10499
--
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