Package org.apache.hadoop.ozone.om
Class OzoneAclUtils
java.lang.Object
org.apache.hadoop.ozone.om.OzoneAclUtils
Ozone Acl Wrapper class.
-
Method Summary
Modifier and TypeMethodDescriptionstatic StringaccessIdToUserPrincipal(String accessID) Converts the given access ID to a kerberos principal.static voidcheckAllAcls(OmMetadataReader omMetadataReader, org.apache.hadoop.ozone.security.acl.OzoneObj.ResourceType resType, org.apache.hadoop.ozone.security.acl.OzoneObj.StoreType storeType, org.apache.hadoop.ozone.security.acl.IAccessAuthorizer.ACLType aclType, String vol, String bucket, String key, String volOwner, String bucketOwner, org.apache.hadoop.security.UserGroupInformation user, InetAddress remoteAddress, String hostName) Check Acls of ozone object with volume owner and bucket owner.static org.apache.hadoop.ozone.security.acl.IAccessAuthorizer.ACLTypegetParentNativeAcl(org.apache.hadoop.ozone.security.acl.IAccessAuthorizer.ACLType aclRight, org.apache.hadoop.ozone.security.acl.OzoneObj.ResourceType resType) get the Parent ACL based on child ACL and resource type.static voidsetOMMultiTenantManager(OMMultiTenantManager tenantManager)
-
Method Details
-
setOMMultiTenantManager
-
accessIdToUserPrincipal
Converts the given access ID to a kerberos principal. If the access ID does not belong to a tenant, the access ID is returned as is to be used as the principal. -
checkAllAcls
public static void checkAllAcls(OmMetadataReader omMetadataReader, org.apache.hadoop.ozone.security.acl.OzoneObj.ResourceType resType, org.apache.hadoop.ozone.security.acl.OzoneObj.StoreType storeType, org.apache.hadoop.ozone.security.acl.IAccessAuthorizer.ACLType aclType, String vol, String bucket, String key, String volOwner, String bucketOwner, org.apache.hadoop.security.UserGroupInformation user, InetAddress remoteAddress, String hostName) throws IOException Check Acls of ozone object with volume owner and bucket owner.- Parameters:
omMetadataReader-resType-storeType-aclType-vol-bucket-key-volOwner-bucketOwner-- Throws:
IOException
-
getParentNativeAcl
public static org.apache.hadoop.ozone.security.acl.IAccessAuthorizer.ACLType getParentNativeAcl(org.apache.hadoop.ozone.security.acl.IAccessAuthorizer.ACLType aclRight, org.apache.hadoop.ozone.security.acl.OzoneObj.ResourceType resType) get the Parent ACL based on child ACL and resource type.- Parameters:
aclRight- child acl as requiredresType- resource type- Returns:
- parent acl
-