Skip to content

Commit

Permalink
Add risk_score indexes for kibana_system_user (#96348)
Browse files Browse the repository at this point in the history
* Add risk_score  indexes for kibana_system_user

* Fix typeo

* Java fix

* Change formatting
  • Loading branch information
nkhristinin authored Jun 8, 2023
1 parent d1d7aea commit 4fa7a94
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -924,7 +924,8 @@ public static RoleDescriptor kibanaSystemRoleDescriptor(String name) {
"logs-cloud_security_posture.vulnerabilities_latest-default*"
)
.privileges("create_index", "read", "index", "delete", IndicesAliasesAction.NAME, UpdateSettingsAction.NAME)
.build() },
.build(),
RoleDescriptor.IndicesPrivileges.builder().indices("risk-score.risk-*").privileges("all").build() },
null,
new ConfigurableClusterPrivilege[] {
new ManageApplicationPrivileges(Set.of("kibana-*")),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1245,6 +1245,9 @@ public void testKibanaSystemRole() {
is(true)
);
});

Arrays.asList("risk-score.risk-score-" + randomAlphaOfLength(randomIntBetween(0, 13)))
.forEach(indexName -> assertAllIndicesAccessAllowed(kibanaRole, indexName));
}

public void testKibanaAdminRole() {
Expand Down

0 comments on commit 4fa7a94

Please sign in to comment.