You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by GitBox <gi...@apache.org> on 2020/06/17 19:04:51 UTC

[GitHub] [hadoop-ozone] smengcl commented on a change in pull request #1087: HDDS-3819. OzoneManager#listVolumeByUser ignores userName parameter when ACL is enabled

smengcl commented on a change in pull request #1087:
URL: https://github.com/apache/hadoop-ozone/pull/1087#discussion_r441770689



##########
File path: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManager.java
##########
@@ -1583,11 +1583,11 @@ private void checkAcls(ResourceType resType, StoreType store,
    *
    * @return true if permission granted, false if permission denied.
    */
-  private boolean hasAcls(ResourceType resType, StoreType store,
-      ACLType acl, String vol, String bucket, String key) {
+  private boolean hasAcls(String userName, ResourceType resType,
+      StoreType store, ACLType acl, String vol, String bucket, String key) {
     try {
       return checkAcls(resType, store, acl, vol, bucket, key,
-          ProtobufRpcEngine.Server.getRemoteUser(),
+          UserGroupInformation.createRemoteUser(userName),

Review comment:
       Question for @xiaoyuyao here: `UserGroupInformation.createRemoteUser()` create a new UGI with `AuthMethod.SIMPLE`. Does this matter?
   
   IMO in this case only username matters.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: ozone-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: ozone-issues-help@hadoop.apache.org