> 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/public-exposure/appsec2-azure-33.md).

# Azure Storage account is not configured with private endpoint connection misconfiguration detected i

## Rule Details

|                        |                                      |
| ---------------------- | ------------------------------------ |
| Cortex AppSec Rule ID  | APPSEC2\_AZURE\_33                   |
| Category - Subcategory | Public Exposure - VPC VCN VNet       |
| Provider               | AZURE                                |
| Severity               | MEDIUM                               |
| Framework              | Terraform, Terraform Plan            |
| Mapped CSPM/KSPM Rule  | 7c773d6c-3225-4f0b-a020-661c48e414b4 |

## Impact

This rule is designed to ensure that a storage account is properly configured with a private endpoint. The private endpoint facilitates a secure connection over a private network, rather than the public internet.

If a storage account is not configured with a private endpoint, it poses a security risk as it might be accessible over the public internet. Unauthorized third parties could potentially gain access to the stored data, which may contain sensitive or proprietary information. Hence, it's crucial for the storage account to be properly configured with a private endpoint to maintain network security and data privacy.

## How to Fix

*Resource:* azurerm\_storage\_account, azurerm\_private\_endpoint

To fix this issue, configure your Azure storage account with a private endpoint.

## In the above code, a private endpoint `example_private_endpoint` is configured for the storage account `examplestoracc`. The `private_service_connection` block connects the storage account to the private endpoint securely. The `subresource_names` item is set to `blob` to specify that the endpoint is for blob storage. Configuring a storage account with a private endpoint ensures that network traffic between the storage account and the endpoint remains within the Azure network, which significantly reduces the risk of data exfiltration. \[source,go]

resource "azurerm\_storage\_account" "example" { name = "examplestoracc" resource\_group\_name = azurerm\_resource\_group.example.name location = azurerm\_resource\_group.example.location account\_tier = "Standard" account\_replication\_type = "GRS"

enable\_https\_traffic\_only = true }

resource "azurerm\_private\_endpoint" "example" { name = "example\_private\_endpoint" location = azurerm\_resource\_group.example.location resource\_group\_name = azurerm\_resource\_group.example.name subnet\_id = azurerm\_subnet.example.id

## private\_service\_connection { name = "example\_psc" is\_manual\_connection = false private\_connection\_resource\_id = azurerm\_storage\_account.example.id subresource\_names = \["blob"] } }


---

# 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/appsec-rules/iac-security/public-exposure/appsec2-azure-33.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.
