@@ -280,7 +280,7 @@ private PrivilegesEvaluatorResponse evaluateSystemIndicesAccess(
280280 .collect (Collectors .toList ());
281281 log .debug ("Service account cannot access regular indices: {}" , regularIndices );
282282 }
283- return PrivilegesEvaluatorResponse .insufficient (action ).reason ("Service account cannot access regular indices" );
283+ return PrivilegesEvaluatorResponse .insufficient ("" ).reason ("Service account cannot access regular indices" );
284284 }
285285 boolean containsProtectedIndex = requestContainsAnyProtectedSystemIndices (requestedResolved );
286286 if (containsProtectedIndex ) {
@@ -332,7 +332,7 @@ private PrivilegesEvaluatorResponse evaluateSystemIndicesAccess(
332332 matchingPluginIndices
333333 );
334334 }
335- return PrivilegesEvaluatorResponse .insufficient (action );
335+ return PrivilegesEvaluatorResponse .insufficient ("" );
336336 }
337337 }
338338 } else {
@@ -357,7 +357,7 @@ private PrivilegesEvaluatorResponse evaluateSystemIndicesAccess(
357357 } else {
358358 auditLog .logSecurityIndexAttempt (request , action , task );
359359 log .warn ("{} for '_all' indices is not allowed for a regular user" , action );
360- return PrivilegesEvaluatorResponse .insufficient (action );
360+ return PrivilegesEvaluatorResponse .insufficient ("" );
361361 }
362362 }
363363 // if system index is enabled and system index permissions are enabled we don't need to perform any further
@@ -370,7 +370,7 @@ else if (containsSystemIndex && !isSystemIndexPermissionEnabled) {
370370 if (log .isDebugEnabled ()) {
371371 log .debug ("Filtered '{}' but resulting list is empty" , securityIndex );
372372 }
373- return PrivilegesEvaluatorResponse .insufficient (action );
373+ return PrivilegesEvaluatorResponse .insufficient ("" );
374374 }
375375 irr .replace (request , false , allWithoutSecurity .toArray (new String [0 ]));
376376 if (log .isDebugEnabled ()) {
@@ -380,7 +380,7 @@ else if (containsSystemIndex && !isSystemIndexPermissionEnabled) {
380380 auditLog .logSecurityIndexAttempt (request , action , task );
381381 final String foundSystemIndexes = String .join (", " , getAllSystemIndices (requestedResolved ));
382382 log .warn ("{} for '{}' index is not allowed for a regular user" , action , foundSystemIndexes );
383- return PrivilegesEvaluatorResponse .insufficient (action );
383+ return PrivilegesEvaluatorResponse .insufficient ("" );
384384 }
385385 }
386386 }
0 commit comments