> For the complete documentation index, see [llms.txt](https://cortex-docs.paloaltonetworks.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cortex-docs.paloaltonetworks.com/posture-rules/cloud-saas-active-directory-posture-rules/cortex-posture-query-based-rules/detection-rules-by-name/azure-log-profile-not-capturing-activity-logs-for-all-regions.md). Agents can also search and read this documentation through its [MCP server](https://cortex-docs.paloaltonetworks.com/~gitbook/mcp).

# Azure log profile not capturing activity logs for all regions

### Synopsis

| Field               | Value                                                         |
| ------------------- | ------------------------------------------------------------- |
| Rule Type           | Detection                                                     |
| Finding Type        | Azure log profile not capturing activity logs for all regions |
| Finding ID          | 60000398                                                      |
| Generates a Finding | This detection rule also generates a finding                  |
| Severity            | Informational                                                 |
| Category            | CONFIGURATION                                                 |
| Cloud Providers     | AZURE                                                         |
| Platform Module     | CSPM                                                          |
| Asset Types         | AZURE\_LOG\_PROFILE                                           |

### Description

Azure log profiles failing to capture activity logs from all regions present a significant security risk. Incomplete logging hinders comprehensive security monitoring and incident response capabilities.

The policy assesses Azure log profiles, specifically their configuration regarding activity log capture across all supported regions. A misconfiguration where logs aren't collected from all regions leaves a blind spot, potentially masking malicious activity originating from unexpected or less frequently monitored locations. Attackers could exploit this gap to remain undetected, compromising sensitive data or resources.

The impact of this misconfiguration includes reduced visibility into potential security breaches. Complete logging across all regions is crucial for effective threat detection, forensic analysis, and regulatory compliance. Comprehensive logging enables security professionals to identify and respond to incidents rapidly, minimizing potential damage.

To mitigate this risk, ensure all Azure log profiles are configured to capture activity logs from all supported regions. Regularly review and update log profile configurations, adding new regions as they become available. Utilize centralized log management and analysis tools to aggregate and monitor logs effectively.

### Remediation

1. Execute the command to check the number of regions present on the account: az account list-locations --query '\[\*].name' | grep -P 'w+' | wc -l
2. Execute the command to check the number of regions added to the log profile: az monitor log-profiles list --query '\[\*].locations' | grep -P 'w+' | wc -l
3. In case there is a difference in the count of regions from step 1 and step 2, Execute the command to list all regions az account list-locations --query '\[\*].name'
4. Use the listed regions from step 3 and Update the Legacy Log profiles activity logs for all regions by following the below URL:

<https://learn.microsoft.com/en-us/azure/azure-monitor/essentials/activity-log?tabs=cli#managing-legacy-log-profiles>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://cortex-docs.paloaltonetworks.com/posture-rules/cloud-saas-active-directory-posture-rules/cortex-posture-query-based-rules/detection-rules-by-name/azure-log-profile-not-capturing-activity-logs-for-all-regions.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
