public static boolean userHasAdministratorAccess(AccessControlList acl, String remoteUser) {
    UserGroupInformation remoteUserUGI = UserGroupInformation.createRemoteUser(remoteUser);
    return acl != null && acl.isUserAllowed(remoteUserUGI);
  }
Get the admin ACLs from the given ServletContext and check if the given user is in the ACL.
@param servletContext the context containing the admin ACL.
@param remoteUser     the remote user to check for.
@return true if the user is present in the ACL, false if no ACL is set or the user is not
        present
hbase-http/src/main/java/org/apache/hadoop/hbase/http/HttpServer.java