| name | cis-azure-foundations-6.1.4 |
| description | Ensure that Azure Monitor Resource Logging is Enabled for All Services that Support it |
| category | cis-azure-foundations |
| version | 5.0.0 |
| author | cyberstrike-official |
| tags | ["cis","azure","logging","monitoring","resource-logging","diagnostic-settings"] |
| cis_id | 6.1.4 |
| cis_benchmark | CIS Microsoft Azure Foundations Benchmark v5.0.0 |
| tech_stack | ["azure"] |
| cwe_ids | [] |
| chains_with | ["cis-azure-foundations-6.1.1.1"] |
| prerequisites | [] |
| severity_boost | {} |
Ensure that Azure Monitor Resource Logging is Enabled for All Services that Support it
Description
Resource Logs capture activity to the data access plane while the Activity log is a subscription-level log for the control plane. Resource-level diagnostic logs provide insight into operations that were performed within that resource itself; for example, reading or updating a secret from a Key Vault. Currently, 95 Azure resources support Azure Monitoring (See the more information section for a complete list), including Network Security Groups, Load Balancers, Key Vault, AD, Logic Apps, and CosmosDB. The content of these logs varies by resource type.
A number of back-end services were not configured to log and store Resource Logs for certain activities or for a sufficient length. It is crucial that monitoring is correctly configured to log all relevant activities and retain those logs for a sufficient length of time. Given that the mean time to detection in an enterprise is 240 days, a minimum retention period of two years is recommended.
While an automated assessment procedure exists for this recommendation, the assessment status remains manual. Determining whether resource logging should be enabled for specific resources depends on the context and requirements of each organization and environment.
Rationale
A lack of monitoring reduces the visibility into the data plane, and therefore an organization's ability to detect reconnaissance, authorization attempts or other malicious activity. Unlike Activity Logs, Resource Logs are not enabled by default. Specifically, without monitoring it would be impossible to tell which entities had accessed a data store that was breached. In addition, alerts for failed attempts to access APIs for Web Services or Databases are only possible when logging is enabled.
This recommendation's Level 1 profile is dependent upon the free level of retention of 30 days. More than 30 days retention of resource logs will increase the cost of this recommendation.
Impact
Costs for monitoring varies with Log Volume. Not every resource needs to have logging enabled. It is important to determine the security classification of the data being processed by the given resource and adjust the logging based on which events need to be tracked. This is typically determined by governance and compliance requirements.
Audit Procedure
Using Azure Portal
The specific steps for configuring resources within the Azure console vary depending on resource, but typically the steps are:
- Go to the resource.
- Click on Diagnostic settings.
- In the blade that appears, click "Add diagnostic setting".
- Configure the diagnostic settings.
- Click on Save.
Using Azure CLI
List all resources for a subscription: