public static void removePrivilege(
      PartialPath path, PrivilegeType priv, List<PathPrivilege> privilegeList) {
    Iterator<PathPrivilege> it = privilegeList.iterator();
    while (it.hasNext()) {
      PathPrivilege pathPri = it.next();
      if (path.matchFullPath(pathPri.getPath())) {
        pathPri.revokePrivilege(priv);
        if (pathPri.getPrivilegeIntSet().isEmpty()) {
          it.remove();
        }
      }
    }
  }
Remove privilege

@param path series path
@param priv privilege type
@param privilegeList privileges in List structure of user or role
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/utils/AuthUtils.java