You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Authz] Allow update settings action for system user (#34030)
When the cluster.routing.allocation.disk.watermark.flood_stage watermark
is breached, DiskThresholdMonitor marks the indices as read-only. This
failed when x-pack security was present as system user does not have the privilege
for update settings action("indices:admin/settings/update").
This commit adds the required privilege for the system user. Also added missing
debug logs when access is denied to help future debugging.
An assert statement is added to catch any missed privileges required for
system user.
Closes#33119
Copy file name to clipboardExpand all lines: x-pack/plugin/core/src/main/java/org/elasticsearch/xpack/core/security/authz/privilege/SystemPrivilege.java
+2-1Lines changed: 2 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -23,7 +23,8 @@ public final class SystemPrivilege extends Privilege {
23
23
"indices:admin/mapping/put", // needed for recovery and shrink api
24
24
"indices:admin/template/put", // needed for the TemplateUpgradeService
25
25
"indices:admin/template/delete", // needed for the TemplateUpgradeService
26
-
"indices:admin/seq_no/global_checkpoint_sync*"// needed for global checkpoint syncs
26
+
"indices:admin/seq_no/global_checkpoint_sync*", // needed for global checkpoint syncs
27
+
"indices:admin/settings/update"// needed for DiskThresholdMonitor.markIndicesReadOnly
27
28
), Automatons.patterns("internal:transport/proxy/*"))); // no proxy actions for system user!
Copy file name to clipboardExpand all lines: x-pack/plugin/core/src/test/java/org/elasticsearch/xpack/core/security/authz/privilege/PrivilegeTests.java
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -126,6 +126,8 @@ public void testSystem() throws Exception {
Copy file name to clipboardExpand all lines: x-pack/plugin/security/src/test/java/org/elasticsearch/xpack/security/authz/AuthorizationServiceTests.java
0 commit comments