You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/storage/common/storage-network-security-set-default-access.md
+16-12Lines changed: 16 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,26 +1,20 @@
1
1
---
2
-
title: Deny Access to Public Endpoints of an Azure Storage account
3
-
description: Put description here.
2
+
title: 'Set the default public network access rule: Azure Storage'
3
+
description: Specify whether to allow networks, disable networks or to permit only specific networks to make requests to the storage accounts public endpoint.
4
4
services: storage
5
5
author: normesta
6
6
ms.service: azure-storage
7
7
ms.subservice: storage-common-concepts
8
8
ms.topic: how-to
9
9
ms.date: 06/18/2025
10
10
ms.author: normesta
11
-
12
11
---
13
-
# Deny access to public endpoints of an Azure Storage account
14
-
15
-
Put something here.
16
12
17
-
## Change the default network access rule
13
+
#Set the default public network access rule of an Azure Storage account
18
14
19
15
By default, storage accounts accept connections from clients on any network. You can limit access to selected networks *or* prevent traffic from all networks and permit access only through a [private endpoint](storage-private-endpoints.md).
20
16
21
-
You must set the default rule to **deny**, or network rules have no effect. However, changing this setting can affect your application's ability to connect to Azure Storage. Be sure to grant access to any allowed networks or set up access through a private endpoint before you change this setting.
@@ -30,9 +24,11 @@ You must set the default rule to **deny**, or network rules have no effect. Howe
30
24
31
25
3. Choose what network access is enabled through the storage account's public endpoint:
32
26
33
-
- Select either **Enabled from all networks** or **Enabled from selected virtual networks and IP addresses**. If you select the second option, you'll be prompted to add virtual networks and IP address ranges.
27
+
- To allow traffic from all networks, select **Enabled from all networks**.
28
+
29
+
- To allow traffic only from specific virtual networks, IP address ranges, or specific Azure resources, select **Enabled from selected virtual networks and IP addresses**. You'll be prompted to add virtual networks, IP address ranges or resource instances.
34
30
35
-
- To restrict inbound access while allowing outbound access, select **Disabled**.
31
+
- To block traffic from all networks,, select **Disabled**.
36
32
37
33
4. Select **Save** to apply your changes.
38
34
@@ -56,6 +52,9 @@ You must set the default rule to **deny**, or network rules have no effect. Howe
> Network rules have no effect unless you set the `-DefaultAction` parameter to `Deny`. However, changing this setting can affect your application's ability to connect to Azure Storage. Be sure to grant access to any allowed networks or set up access through a private endpoint before you change this setting.
57
+
59
58
- To block traffic from all networks, use the `Set-AzStorageAccount` command and set the `-PublicNetworkAccess` parameter to `Disabled`. Traffic will be allowed only through a [private endpoint](storage-private-endpoints.md). You'll have to create that private endpoint.
60
59
61
60
```powershell
@@ -64,6 +63,8 @@ You must set the default rule to **deny**, or network rules have no effect. Howe
1. Install the [Azure CLI](/cli/azure/install-azure-cli) and [sign in](/cli/azure/authenticate-azure-cli).
68
69
69
70
2. Choose which type of public network access you want to allow:
@@ -80,6 +81,9 @@ You must set the default rule to **deny**, or network rules have no effect. Howe
80
81
az storage account update --resource-group "myresourcegroup" --name "mystorageaccount" --default-action Deny
81
82
```
82
83
84
+
> [!IMPORTANT]
85
+
> Network rules have no effect unless you set the `--default-action` parameter to `Deny`. However, changing this setting can affect your application's ability to connect to Azure Storage. Be sure to grant access to any allowed networks or set up access through a private endpoint before you change this setting.
86
+
83
87
- To block traffic from all networks, use the `az storage account update` command and set the `--public-network-access` parameter to `Disabled`. Traffic will be allowed only through a [private endpoint](storage-private-endpoints.md). You'll have to create that private endpoint.
0 commit comments