private static void resetAcls(final Configuration conf, boolean eraseAcls) throws Exception {
    try (ZKWatcher zkw = new ZKWatcher(conf, "ZKAclReset", null)) {
      LOG.info((eraseAcls ? "Erase" : "Set") + " HBase ACLs for {} {}", zkw.getQuorum(),
        zkw.getZNodePaths().baseZNode);
      resetAcls(zkw, zkw.getZNodePaths().baseZNode, eraseAcls);
    }
  }
You may add the jaas.conf option -Djava.security.auth.login.config=/PATH/jaas.conf You may also
specify -D to set options "hbase.zookeeper.quorum" (it should be in hbase-site.xml)
"zookeeper.znode.parent" (it should be in hbase-site.xml) Use -set-acls to set the ACLs, no
option to erase ACLs
hbase-zookeeper/src/main/java/org/apache/hadoop/hbase/zookeeper/ZKAclReset.java