Microsoft Sentinel
Cloud and workloads

Resource Context Rbac

In brief

The article now provides clearer guidance for users needing access to specific workspace data, revises the architecture description, and expands the Logstash example to explain Beats input, the Microsoft Sentinel output plugin, and the `azure_resource_id` field.

What Defender admins need to know

Administrators can use the clarified procedure and Logstash example when configuring resource-context RBAC for non-Azure data.

Summaries are generated from the documentation change itself.

Documentation change

The comparison below shows only the changed extract. Use the full-page view for complete context.

#Customer intent: As a security administrator, I want to understand when to use Azure RBAC at the resource-context level so that I can grant specific data access to users without exposing the entire Microsoft Sentinel environment.

However, you may have some users who need to access only specific data in your workspace, but shouldn't have access to the entire Microsoft Sentinel environment. For example, you may want to provide a non-security operations (non-SOC) team with access to the Windows event data for the servers they own.

In such cases,For users who need access only to specific data in the workspace, we recommend that you configure your role-based access control (RBAC) based on the resources that are allowed to yourthose users, instead of providing them with access to the workspace or specific Microsoft Sentinel features. This method is also known as setting up resource-context RBAC.

When users have access to Microsoft Sentinel data via the resources they can access instead of the workspace, they can view logs and workbooks using the following methods:

Diagram of a sample architecture for resource-context RBAC.

In this image:the sample resource-context RBAC architecture diagram:

  • The Log Analytics workspace enabled for Microsoft Sentinel is placed in a separate subscription to better isolate permissions from the subscription that the applications teams use to host their workloads.
  • The applications teams are granted access to their respective resource groups, where they can manage their resources.

ThisPlacing the workspace in a separate subscription and using resource-context RBAC allows theseapplication teams to view logs generated by any resources they have access to, even when the logs are stored in a workspace where they don't have direct access. The applications teams can access their logs via the Logs area of the Azure portal, to show logs for a specific resource, or via Azure Monitor, to show all of the logs they can access at the same time.

Explicitly configure resource-context RBAC for non-Azure resources

Azure resources have built-in support for resource-context RBAC, but might require additional fine-tuning when working with non-Azure resources. For example, data in your Log Analytics workspace enabled for Microsoft Sentinel that are not Azure resources include Syslog, CEF, or AADMicrosoft Entra ID data, or data collected by a custom collector.

UseTo configure resource-context RBAC for non-Azure data, complete the following steps if you want to configure resource-context RBAC, but your data is not an Azure resource.procedure.

To explicitly configure resource-context RBAC:

If you are collecting your data using the Microsoft Sentinel Logstash output plugin, use the azure_resource_id field to configure your custom collector to include the resource ID in your output.

If you are using resource-context RBAC and want the events collected by API to be available to specific users, use the resource ID of the resource group you configured in Explicitly configure resource-context RBAC for non-Azure resources.

For example, the following code shows a sample Logstash configuration file:file shows how to ingest events via Beats input and send them to a Log Analytics workspace using the Microsoft Sentinel output plugin, with the azure_resource_id field set to tag events with a specific resource group for resource-context RBAC:

 input {

When collecting using the [Log Analytics data collector API](/azure/azure-monitor/logs/data-collector-api), you can assign to events with a resource ID using the HTTP [*x-ms-AzureResourceId*](/azure/azure-monitor/logs/data-collector-api#request-headers) request header.

If you are using resource-context RBAC and want the events collected by API to be available to specific users, use the resource ID of the resource group you [createdconfigured in [Explicitly configure resource-context RBAC for your users]non-Azure resources](#explicitly-configure-resource-context-rbac-for-non-azure-resources).

## Alternatives to resource-context RBAC

Depending on the permissions required in your organization, using resource-context RBAC may not provide a full solution.fully satisfy all data-access requirements in your organization. For example, consider if an organization that uses the organization whoseseparate-subscription workspace architecture is described in the previous section[Scenarios for resource-context RBAC](#scenarios-for-resource-context-rbac) must also grant access to Office 365 logs to an internal audit team. In this case, they might use *table-level RBAC* to grant the audit team with access to the entire **OfficeActivity** table, without granting permissions to any other table.

The following list describes scenarios where other solutions for data access may fit your requirements better: