π Azure Subscription Log Analytics Agent is not auto provisioned π’
- Contextual name: π Log Analytics Agent is not auto provisioned π’
- ID:
/ce/ca/azure/subscription/log-analytics-agent-auto-provisioning
- Located in: π Azure Subscription
Flagsβ
- π’ Policy with categories
- π’ Policy with type
- π’ Production policy
Our Metadataβ
- Policy Type:
COMPLIANCE_POLICY
- Policy Category:
SECURITY
Similar Policiesβ
- Cloud Conformity
- Internal
dec-x-181422d8
Similar Internal Rulesβ
Rule | Policies | Flags |
---|---|---|
βοΈ dec-x-181422d8 | 1 |
Logicβ
- π§ prod.logic.yaml π’
Descriptionβ
Descriptionβ
Enable automatic provisioning of the monitoring agent to collect security data.
DEPRECATION PLANNED: The Log Analytics Agent is slated for deprecation in August 2024. The Microsoft Defender for Endpoint agent, in tandem with new agentless capabilities will be providing replacement functionality. More detail is available here: https://techcommunity.microsoft.com/t5/microsoft-defender-for-cloud/microsoft-defender-for-cloud-strategy-and-plan-towards-log/ba-p/3883341.
Rationaleβ
When
Log Analytics agent for Azure VMs
is turned on, Microsoft Defender for Cloud provisions the Microsoft Monitoring Agent on all existing supported Azure virtual machines and any new ones that are created. The Microsoft Monitoring Agent scans for various security-related configurations and events such as system updates, OS vulnerabilities, endpoint protection, and provides alerts.Auditβ
From Azure Portalβ
- From Azure Home select the Portal Menu.
- Select
Microsoft Defender for Cloud
.- Under
Management
, selectEnvironment Settings
.... see more
Remediationβ
Remediationβ
From Azure Portalβ
- From Azure Home select the Portal Menu.
- Select
Microsoft Defender for Cloud
.- Under
Management
, selectEnvironment Settings
.- Select a subscription.
- Click on
Settings & monitoring
.- Set the
Status
ofLog Analytics agent
toOn
.- Select a Workspace.
- Click
Apply
.- Click
Continue
.Repeat the above for any additional subscriptions.
From Azure CLIβ
Use the below command to set
Automatic provisioning of monitoring agent
toOn
:az account get-access-token --query "{subscription:subscription,accessToken:accessToken}" --out tsv | xargs -L1 bash -c 'curl -X PUT -H "Authorization: Bearer $1" -H "Content-Type: application/json" https://management.azure.com/subscriptions/subscriptionID/providers/Microsoft.Security/autoProvisioningSettings/default?api-version=2017-08-01-preview -d@"input.json"'
Where
input.json
contains the Request body json data as mentioned below:{
"id": "/subscriptions/<Your_Subscription_Id>/providers/Microsoft.Security/autoProvisioningSettings/default",
... [see more](remediation.md)