Hello Anmol,
I would suggest a way to restrict these vulnerability states data for the custom read-only users and still be available for your admin user instead of deactivating the vulnerability detection module entirely. As I already mentioned, the vulnerability states for the active vulnerability across your endpoints are getting indexed in a separate index pattern ( wazuh-states-vulnerabilities-*) in your indexer. Now for the custom RBAC users whom you do not want to give access to this index and relevant visualizations, you can restrict that with a document level security.
You can Add another index permission in the step 3 of Creating and mapping an internal user as below:
Index: wazuh-states-vulnerabilities-*
Index permissions: read
Document level security:
{
"bool": {
"must": {
"exists": {
"field": "agent.group"
}
}
}
}
This would be a trick to restrict the wazuh-states-vulnerabilities-* index entirely for the users mapped to this role as there is no field named agent.group available in those vulnerability states. However, you can still see the vulnerability detection dashboard and inventory with your admin users.