Integration
VirtualMetric Director supports Microsoft Sentinel integration through two different approaches: automatic discovery and manual configuration. Choose the method that best fits your environment and requirements.
Prerequisites
Both integration approaches require:
- an Azure subscription with permissions to create resources
- a Log Analytics workspace required by Microsoft Sentinel
Autodiscovery Setup
VirtualMetric Director provides an autodiscovery feature for Microsoft Sentinel integration. This enables automatic detection and configuration of Data Collection Rules (DCRs) and their associated streams, simplifying the setup process and providing dynamic updates as your Sentinel environment changes.
Open a terminal with Administrative access and navigate to <vm_root>. Then, type the following command and press
- PowerShell
- Bash
C:\vmetric-director -sentinel -autodiscovery
vmetric-director -sentinel -autodiscovery
Follow the on-screen prompts to complete the setup process. For detailed step-by-step instructions, refer to Microsoft Sentinel Overview.
Manual Setup
Manual integration requires step-by-step configuration of Microsoft Sentinel components. This approach provides full control over the integration process and is ideal for environments requiring specific configuration requirements.
Service Principal Setup
Create a service principal for DataStream authentication:
- Navigate to Azure Active Directory > App registrations
- Select New registration
- Enter DataStream as the application name
- Select Accounts in this organizational directory only
- Click Register
- Record the Application (client) ID and Directory (tenant) ID
- Go to Certificates & secrets > New client secret
- Create a secret and record the Client secret value
Data Collection Endpoint Setup
- Navigate to Azure Portal > Monitor > Data Collection Endpoints
- Select Create
- Configure the DCE:
Field Value Name datastream-dceResource group Select your resource group Region Same region as your Log Analytics workspace - Click Review + create > Create
- Record the Logs Ingestion endpoint URL
Data Collection Rule Creation
- Navigate to Monitor > Data Collection Rules
- Select Create
- Configure basic settings:
Field Value Rule name datastream-dcrResource group Same as your DCE Region Same as your DCE Platform Type Windows or Linux based on your data sources - In Resources tab: add your Log Analytics workspace
- In Collect and deliver tab,
Field Value Data source type Custom Text Logs or Windows Event Logs Data source name DataStreamLogsFile pattern Configure based on your log sources - Configure Destination:
Field Value Destination type Azure Monitor Logs Destination Your Log Analytics workspace Table Create or select target table - Click Review + create > Create
- Record the DCR Immutable ID
Required Permissions
Director needs the following permissions for Microsoft Sentinel integration.
If you used the Automation tool with App Registration, these permissions are already configured.
- Autodiscovery
- Manual
-
For Data Collection - For each DCR name prefixed with vmetric:
- Navigate to the DCR in Azure Portal
- Go to Access Control (IAM)
- Select Add > Add role assignment
- Assign the following permissions:
Role Assignee Monitoring Metrics Publisher Your Managed Identity
-or-
Application
-
For Autodiscovery - To enable the DCR autodiscovery features:
- Navigate to the Resource Group containing your DCRs
- Go to Access Control (IAM)
- Select Add > Add role assignment
- Assign the following permissions:
Role Assignee Monitoring Reader Your Managed Identity
-or-
ApplicationimportantThe
Monitoring Readerrole should be assigned at the Resource Group level only. Assigning this role at the Subscription level is not recommended since it is not required for the functionality to work, and it increases the autodiscovery scan duration.
-
For Data Collection - For each manually created DCR:
- Navigate to the DCR in Azure Portal
- Go to Access Control (IAM)
- Select Add > Add role assignment
- Assign the following permissions:
Role Assignee Monitoring Metrics Publisher Your Service Principal
-or-
Application
Configuration
- Autodiscovery
- Manual
Basic Configuration
targets:
- name: sentinel
type: sentinel
properties:
tenant_id: "<your-tenant-id>"
client_id: "<your-client-id>"
client_secret: "<your-client-secret>"
endpoint: "/subscriptions/.../dataCollectionEndpoints/<your-dce-name>" # Use Resource ID
Filtered Streams
You can filter the autodiscovered streams that you intend to use:
targets:
- name: sentinel
type: sentinel
properties:
tenant_id: "<your-tenant-id>"
client_id: "<your-client-id>"
client_secret: "<your-client-secret>"
endpoint: "/subscriptions/.../dataCollectionEndpoints/<your-dce-name>"
streams:
- name: "Custom-WindowsEvent"
- name: "Custom-SecurityEvent"
Cache Configuration
You can optionally adjust the cache timeout (in seconds):
targets:
- name: sentinel
type: sentinel
properties:
endpoint: "/subscriptions/.../dataCollectionEndpoints/<your-dce-name>"
cache:
timeout: 300
Basic Configuration
targets:
- name: sentinel
type: sentinel
properties:
tenant_id: "<your-tenant-id>"
client_id: "<your-client-id>"
client_secret: "<your-client-secret>"
endpoint: "https://<dce-name>-<region>.ingest.monitor.azure.com" # Direct URL
streams:
- name: "Custom-DataStreamLogs"
dcr_id: "dcr-<immutable-id>"
Multi-Stream Configuration
For multiple tables and streams:
targets:
- name: sentinel
type: sentinel
properties:
tenant_id: "<your-tenant-id>"
client_id: "<your-client-id>"
client_secret: "<your-client-secret>"
endpoint: "https://<dce-name>-<region>.ingest.monitor.azure.com"
streams:
- name: "Custom-SecurityEvents"
dcr_id: "dcr-<security-dcr-id>"
- name: "Custom-NetworkEvents"
dcr_id: "dcr-<network-dcr-id>"
- name: "Custom-SystemEvents"
dcr_id: "dcr-<system-dcr-id>"