I am using ldap backend groups mapped to different roles which works fine,
but am having problem with permissions when a specific backend group is mapped to multiple different opensearch roles.
It seems like the opensearch role with most restrictive permissions beats the role which has higher permissions,
is that by design or is there a way to overcome this ?
Example:
<roles.yml>
Custom roles
Index Mgmt (view access)
With this role you can view “Discover” and “Stack Mgmt - Index Patterns”,“Index Mgmt - Indices”
test-app-role
With this role you can view “Discover” and “Stack Mgmt - Index Patterns”
But you cannot list Indices within “Index Mgmt - Indices”,
you get an “indices:admin/aliases/get” permission error, only way to solve this is to change index pattern to “*”
If group is member of both roles it still does not work.
view-all-indices:
reserved: true
backend_roles:
“ldap_test_app_group”
test-app-role:
reserved: true
backend_roles:
“ldap_test_app_group”
Thing is that the “test-app-role” should be able to read/write/search its own index1 AND list all other indices
Would really appreciate if someone are able to help with this issue
test-app-role:
Added the index pattern “.kibana*” to the list and kept the “index1*” , but the test user still does not have the permission to see/list all indexes.
[2023-05-08T13:04:20,031][INFO ][o.o.s.p.PrivilegesEvaluator] [opensearch] No index-level perm match for User [name=api-test, backend_roles=[api-test]
[2023-05-08T13:04:20,031][INFO ][o.o.s.p.PrivilegesEvaluator] [opensearch] No permissions for [indices:admin/data_stream/get]
I’ve tested your roles and when I use api-test role then I can’t list the indices in “Index Mgmt - Indices”. However, when both are assigned then I can list indices.
Could you share your opensearch_dashbaords.yml file?
Issue still remains even though I removed the line,
opensearch.ssl.certificateAuthorities: [“/usr/opensearch/config/cert/ca.pem”] from opensearch_dashboards.yml
When the user logs into the GUI and tries to view all the Indices under Index Mgmt the following error occurs:
“[security_exception] no permissions for [indices:monitor/recovery] and User [name=api-test, backend_roles=[api-test], requestedTenant=]”