> 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/appsec-rules/iac-security/networking/appsec2-azure-24.md).

# Azure Automation account configured with overly permissive network access misconfiguration detected

## Rule Details

|                        |                                      |
| ---------------------- | ------------------------------------ |
| Cortex AppSec Rule ID  | APPSEC2\_AZURE\_24                   |
| Category - Subcategory | Public Exposure - Ingress Controls   |
| Provider               | AZURE                                |
| Severity               | MEDIUM                               |
| Framework              | Terraform, Terraform Plan            |
| Mapped CSPM/KSPM Rule  | d7518237-8ab1-4770-b6e6-6c8d4ca46839 |

## Impact

This rule checks if Azure Automation accounts have overly permissive network access. Azure Automation is a service in Azure that allows you to automate frequent, time-consuming, and error-prone cloud management tasks. This rule checks whether the Azure Automation service has been given more network access permissions than necessary.

Having overly permissive network access is bad because it exposes the automation service and hence the resources being managed to potential threats. If an attacker gains access, they may be able to use the automation account and its permissions to manipulate resources or data, perform actions detrimental to the system, or gain access to sensitive information.

Ensuring that the Azure Automation account follows the principle of least privilege, where it only has the minimum permissions necessary to perform its tasks, reduces the potential attack surface and enhances security.

## How to Fix

*Resource:* azurerm\_automation\_account

* *Arguments:* public\_network\_access\_enabled

You must set the public\_network\_access\_enabled attribute to false in your azurerm\_automation\_account resource. This configuration restricts the Azure Automation account from being accessed over the public internet. Here's an example Terraform configuration for an Azure Automation account with restricted network access:

## In this Terraform example, an azurerm\_automation\_account resource is defined with public\_network\_access\_enabled set explicitly to false. This setting ensures the automation account can only be accessed through private endpoints within the Azure network. \[source,go]

resource "azurerm\_automation\_account" "example" { name = "example-automation-account" location = "East US" resource\_group\_name = "example-resources"

sku\_name = "Basic"

public\_network\_access\_enabled = false }

***


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://cortex-docs.paloaltonetworks.com/appsec-rules/iac-security/networking/appsec2-azure-24.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
