2.11 Ensure that 'Automatic provisioning of monitoring agent' is set to 'On'

Warning! Audit Deprecated

This audit has been deprecated and will be removed in a future update.

View Next Audit Version

Information

Enable automatic provisioning of the monitoring agent to collect security data.

Rationale:

When Automatic provisioning of monitoring agent is turned on, Azure Security Center 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.

Solution

From Azure Console

Go to Security Center

Click on Pricing & Settings

Click on a subscription

Click on Data Collection

Set Automatic provisioning to On

Click save

Repeat the above for any additional subscriptions.
Using Azure Command Line Interface 2.0
Use the below command to set Automatic provisioning of monitoring agent to On.

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/$0/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',
'name': 'default',
'type': 'Microsoft.Security/autoProvisioningSettings',
'properties': {
'autoProvision': 'On'
}
}

Default Value:

By default, Automatic provisioning of monitoring agent is set to On.

See Also

https://workbench.cisecurity.org/files/3459