Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Commit

Permalink
odfe security fix (#1048)
Browse files Browse the repository at this point in the history
  • Loading branch information
davidcui1225 authored Feb 12, 2021
1 parent e3aa580 commit 7781362
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ protected RestClient buildClient(Settings settings, HttpHost[] hosts) throws IOE
configureClient(builder, settings);
}

builder.setStrictDeprecationMode(true);
builder.setStrictDeprecationMode(false);
return builder.build();
}

Expand All @@ -84,7 +84,7 @@ protected static void wipeAllODFEIndices() throws IOException {
JSONObject jsonObject = (JSONObject) object;
String indexName = jsonObject.getString("index");
//.opendistro_security isn't allowed to delete from cluster
if (!".opendistro_security".equals(indexName)) {
if (!indexName.startsWith(".kibana") && !indexName.startsWith(".opendistro")) {
client().performRequest(new Request("DELETE", "/" + indexName));
}
}
Expand Down

0 comments on commit 7781362

Please sign in to comment.