-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HBASE-27528 log duplication issues in MasterRpcServices. #4951
Conversation
delete the auditlog from grant and revoke in MasterRpcServices.
🎊 +1 overall
This message was automatically generated. |
🎊 +1 overall
This message was automatically generated. |
So the intention here is that, only if we have already enabled AccessChecker, calling grant and revoke is useful? |
@Apache9 |
I mean the removal seems OK, as if we do not enable AccessChecker, it does not make sense to call grant and revoke methods. |
Request review from @apurtell and @wchevreuil. Will merge later if no objections. Thanks. |
Signed-off-by: Duo Zhang <zhangduo@apache.org> (cherry picked from commit 913cf6b)
Thanks for your review! |
HBASE-27528 MasterRpcServices record audit log in privileged operations (grant, revoke).
but I found a path from
server.cpHost.preRevoke(userPermission);
toAccessChecker audit log
(
preRevoke -> MasterCoprocessorHost.preRevoke -> AccessController.preRevoke -> preGrantOrRevoke -> accessChecker.requireXXXPermission -> logResult -> AUDITLOG.trace...
), which caused log duplication:the
logResult
auditlog contain all the infomation recorded byMasterRpcServices.revoke
(user, remote address, permission
) :Since AccessChecker integrates auditlogs for permission check, I'll delete the log in MasterRpcServices.
And grant has the same problem.