Skip to content

Commit e85bc4e

Browse files
committed
refactor for forced tunneling requirement
1 parent 1ebbcc2 commit e85bc4e

File tree

1 file changed

+70
-79
lines changed

1 file changed

+70
-79
lines changed

articles/firewall/deploy-firewall-basic-portal-policy.md

Lines changed: 70 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ services: firewall
55
author: vhorne
66
ms.service: firewall
77
ms.topic: how-to
8-
ms.date: 09/07/2022
8+
ms.date: 09/12/2022
99
ms.author: victorh
1010
ms.custom: mvc
1111
#Customer intent: As an administrator new to this service, I want to control outbound network access from resources located in an Azure subnet.
@@ -26,16 +26,15 @@ One way you can control outbound network access from an Azure subnet is with Azu
2626

2727
Network traffic is subjected to the configured firewall rules when you route your network traffic to the firewall as the subnet default gateway.
2828

29-
For this how-to, you create a simplified single VNet with two subnets for easy deployment.
30-
31-
For production deployments, a [hub and spoke model](/azure/architecture/reference-architectures/hybrid-networking/hub-spoke) is recommended, where the firewall is in its own VNet. The workload servers are in peered VNets in the same region with one or more subnets.
29+
For this how-to, you create a simplified single VNet with three subnets for easy deployment. The Firewall Basic Preview is deployed in forced tunnelling mode to allow for traffic throughput control.
3230

3331
* **AzureFirewallSubnet** - the firewall is in this subnet.
32+
* **AzureFirewallManagementSubnet** - for service management traffic.
3433
* **Workload-SN** - the workload server is in this subnet. This subnet's network traffic goes through the firewall.
3534

36-
![Tutorial network infrastructure](media/tutorial-firewall-deploy-portal/tutorial-network.png)
35+
For production deployments, a [hub and spoke model](/azure/architecture/reference-architectures/hybrid-networking/hub-spoke) is recommended, where the firewall is in its own VNet. The workload servers are in peered VNets in the same region with one or more subnets.
3736

38-
In this tutorial, you learn how to:
37+
In this how-to, you learn how to:
3938

4039
> [!div class="checklist"]
4140
> * Set up a test network environment
@@ -52,67 +51,84 @@ If you prefer, you can complete this procedure using [Azure PowerShell](deploy-p
5251

5352
If you don't have an Azure subscription, create a [free account](https://azure.microsoft.com/free/?WT.mc_id=A261C142F) before you begin.
5453

55-
## Set up the network
54+
### Enable Firewall Basic
55+
56+
For the preview, you must enable Firewall Basic before you begin.
5657

57-
First, create a resource group to contain the resources needed to deploy the firewall. Then create a VNet, subnets, and a test server.
58+
```azurepowershell
59+
Connect-AzAccount
60+
Select-AzSubscription -Subscription "subscription_id or subscription_name"
61+
Register-AzProviderFeature -FeatureName AzureFirewallBasic -ProviderNamespace Microsoft.Network
62+
Register-AzResourceProvider -ProviderNamespace Microsoft.Network
63+
```
5864

59-
### Create a resource group
65+
## Create a resource group
6066

61-
The resource group contains all the resources for the tutorial.
67+
The resource group contains all the resources for the how-to.
6268

6369
1. Sign in to the Azure portal at [https://portal.azure.com](https://portal.azure.com).
64-
2. On the Azure portal menu, select **Resource groups** or search for and select *Resource groups* from any page. Then select **Add**.
70+
2. On the Azure portal menu, select **Resource groups** or search for and select *Resource groups* from any page. Then select **Create**.
6571
4. For **Subscription**, select your subscription.
6672
1. For **Resource group name**, enter *Test-FW-RG*.
6773
1. For **Region**, select a region. All other resources that you create must be in the same region.
6874
1. Select **Review + create**.
6975
1. Select **Create**.
7076

71-
### Create a VNet
72-
73-
This VNet will have two subnets.
77+
## Deploy the firewall and policy
7478

75-
> [!NOTE]
76-
> The size of the AzureFirewallSubnet subnet is /26. For more information about the subnet size, see [Azure Firewall FAQ](firewall-faq.yml#why-does-azure-firewall-need-a--26-subnet-size).
79+
Deploy the firewall and create associated network infrastructure.
7780

7881
1. On the Azure portal menu or from the **Home** page, select **Create a resource**.
79-
1. Select **Networking**.
80-
1. Search for **Virtual network** and select it.
81-
1. Select **Create**.
82-
1. For **Subscription**, select your subscription.
83-
1. For **Resource group**, select **Test-FW-RG**.
84-
1. For **Name**, type **Test-FW-VN**.
85-
1. For **Region**, select the same location that you used previously.
86-
1. Select **Next: IP addresses**.
87-
1. For **IPv4 Address space**, accept the default **10.0.0.0/16**.
88-
1. Under **Subnet**, select **default**.
89-
1. For **Subnet name** change the name to **AzureFirewallSubnet**. The firewall will be in this subnet, and the subnet name **must** be AzureFirewallSubnet.
90-
1. For **Address range**, type **10.0.1.0/26**.
91-
1. Select **Save**.
82+
2. Type **firewall** in the search box and press **Enter**.
83+
3. Select **Firewall** and then select **Create**.
84+
4. On the **Create a Firewall** page, use the following table to configure the firewall:
85+
86+
|Setting |Value |
87+
|---------|---------|
88+
|Subscription |\<your subscription\>|
89+
|Resource group |**Test-FW-RG** |
90+
|Name |**Test-FW01**|
91+
|Region |Select the same location that you used previously|
92+
|Firewall Tier|**Basic (Preview)**|
93+
|Firewall management|**Use a Firewall Policy to manage this firewall**|
94+
|Firewall policy|**Add new**:<br>**fw-test-pol**<br>Your selected region<br>Policy tier should default to **Basic**
95+
|Choose a virtual network |**Create new**<br> Name: **Test-FW-VN**<br>Address space: **10.0.0.0/16**<br>Subnet address space: **10.0.0.0/26**|
96+
|Public IP address |**Add new**:<br>**Name**: **fw-pip**|
97+
|Management - Subnet address space| **10.0.1.0/26**|
98+
|Management public IP address| **Add new**<br>**fw-mgmt-pip**
9299

93-
Next, create a subnet for the workload server.
100+
5. Accept the other default values, then select **Review + create**.
101+
6. Review the summary, and then select **Create** to create the firewall.
102+
103+
This will take a few minutes to deploy.
104+
7. After deployment completes, go to the **Test-FW-RG** resource group, and select the **Test-FW01** firewall.
105+
8. Note the firewall private and public IP (fw-pip) addresses. You'll use these addresses later.
94106

95-
1. Select **Add subnet**.
96-
4. For **Subnet name**, type **Workload-SN**.
97-
5. For **Subnet address range**, type **10.0.2.0/24**.
98-
6. Select **Add**.
99-
7. Select **Review + create**.
100-
8. Select **Create**.
107+
## Create a subnet for the workload server
101108

102-
### Create a virtual machine
109+
Next, create a subnet for the workload server.
110+
111+
1. Go to the Test-FW-RG resource group and select the **Test-FW-VN** virtual network.
112+
1. Select **Subnets**.
113+
1. Select **Subnet**.
114+
1. For **Subnet name**, type **Workload-SN**.
115+
1. For **Subnet address range**, type **10.0.2.0/24**.
116+
1. Select **Save**.
117+
118+
## Create a virtual machine
103119

104120
Now create the workload virtual machine, and place it in the **Workload-SN** subnet.
105121

106122
1. On the Azure portal menu or from the **Home** page, select **Create a resource**.
107-
2. Select **Windows Server 2016 Datacenter**.
123+
2. Select **Windows Server 2019 Datacenter**.
108124
4. Enter these values for the virtual machine:
109125

110126
|Setting |Value |
111127
|---------|---------|
112128
|Resource group |**Test-FW-RG**|
113129
|Virtual machine name |**Srv-Work**|
114130
|Region |Same as previous|
115-
|Image|Windows Server 2016 Datacenter|
131+
|Image|Windows Server 2019 Datacenter|
116132
|Administrator user name |Type a user name|
117133
|Password |Type a password|
118134

@@ -122,45 +138,18 @@ Now create the workload virtual machine, and place it in the **Workload-SN** sub
122138
8. Make sure that **Test-FW-VN** is selected for the virtual network and the subnet is **Workload-SN**.
123139
9. For **Public IP**, select **None**.
124140
11. Accept the other defaults and select **Next: Management**.
125-
12. Select **Disable** to disable boot diagnostics. Accept the other defaults and select **Review + create**.
126-
13. Review the settings on the summary page, and then select **Create**.
141+
1. Select **Next: Monitoring**.
142+
1. Select **Disable** to disable boot diagnostics. Accept the other defaults and select **Review + create**.
143+
1. Review the settings on the summary page, and then select **Create**.
127144
1. After the deployment completes, select the **Srv-Work** resource and note the private IP address for later use.
128145

129-
## Deploy the firewall and policy
130-
131-
Deploy the firewall into the VNet.
132-
133-
1. On the Azure portal menu or from the **Home** page, select **Create a resource**.
134-
2. Type **firewall** in the search box and press **Enter**.
135-
3. Select **Firewall** and then select **Create**.
136-
4. On the **Create a Firewall** page, use the following table to configure the firewall:
137-
138-
|Setting |Value |
139-
|---------|---------|
140-
|Subscription |\<your subscription\>|
141-
|Resource group |**Test-FW-RG** |
142-
|Name |**Test-FW01**|
143-
|Region |Select the same location that you used previously|
144-
|Firewall Tier|**Basic**|
145-
|Firewall management|**Use a Firewall Policy to manage this firewall**|
146-
|Firewall policy|**Add new**:<br>**fw-test-pol**<br>Policy tier should default to **Basic**<br>Your selected region
147-
|Choose a virtual network |**Use existing**: **Test-FW-VN**|
148-
|Public IP address |**Add new**:<br>**Name**: **fw-pip**|
149-
150-
5. Accept the other default values, then select **Review + create**.
151-
6. Review the summary, and then select **Create** to create the firewall.
152-
153-
This will take a few minutes to deploy.
154-
7. After deployment completes, go to the **Test-FW-RG** resource group, and select the **Test-FW01** firewall.
155-
8. Note the firewall private and public IP addresses. You'll use these addresses later.
156-
157146
## Create a default route
158147

159148
For the **Workload-SN** subnet, configure the outbound default route to go through the firewall.
160149

161150
1. On the Azure portal menu, select **All services** or search for and select *All services* from any page.
162151
2. Under **Networking**, select **Route tables**.
163-
3. Select **Add**.
152+
3. Select **Create**.
164153
5. For **Subscription**, select your subscription.
165154
6. For **Resource group**, select **Test-FW-RG**.
166155
7. For **Region**, select the same location that you used previously.
@@ -177,12 +166,13 @@ After deployment completes, select **Go to resource**.
177166
13. Select **OK**.
178167
14. Select **Routes** and then select **Add**.
179168
15. For **Route name**, type **fw-dg**.
180-
16. For **Address prefix**, type **0.0.0.0/0**.
181-
17. For **Next hop type**, select **Virtual appliance**.
169+
1. For **Address prefix destination**, select **IP Addresses**.
170+
1. For **Destination IP addresses/CIDR ranges**, type **0.0.0.0/0**.
171+
1. For **Next hop type**, select **Virtual appliance**.
182172

183173
Azure Firewall is actually a managed service, but virtual appliance works in this situation.
184174
18. For **Next hop address**, type the private IP address for the firewall that you noted previously.
185-
19. Select **OK**.
175+
19. Select **Add**.
186176

187177
## Configure an application rule
188178

@@ -220,7 +210,7 @@ This is the network rule that allows outbound access to two IP addresses at port
220210
1. For **Protocol**, select **UDP**.
221211
1. For **Destination Ports**, type **53**.
222212
1. For **Destination type** select **IP address**.
223-
1. For **Destination**, type **209.244.0.3,209.244.0.4**.<br>These are public DNS servers operated by CenturyLink.
213+
1. For **Destination**, type **209.244.0.3,209.244.0.4**.<br>These are public DNS servers operated by Level3.
224214
2. Select **Add**.
225215

226216
## Configure a DNAT rule
@@ -238,15 +228,15 @@ This rule allows you to connect a remote desktop to the Srv-Work virtual machine
238228
1. For **Protocol**, select **TCP**.
239229
1. For **Destination Ports**, type **3389**.
240230
1. For **Destination Type**, select **IP Address**.
241-
1. For **Destination**, type the firewall public IP address.
231+
1. For **Destination**, type the firewall public IP address (fw-pip).
242232
1. For **Translated address**, type the **Srv-work** private IP address.
243233
1. For **Translated port**, type **3389**.
244234
1. Select **Add**.
245235

246236

247237
### Change the primary and secondary DNS address for the **Srv-Work** network interface
248238

249-
For testing purposes in this tutorial, configure the server's primary and secondary DNS addresses. This isn't a general Azure Firewall requirement.
239+
For testing purposes in this how-to, configure the server's primary and secondary DNS addresses. This isn't a general Azure Firewall requirement.
250240

251241
1. On the Azure portal menu, select **Resource groups** or search for and select *Resource groups* from any page. Select the **Test-FW-RG** resource group.
252242
2. Select the network interface for the **Srv-Work** virtual machine.
@@ -260,24 +250,25 @@ For testing purposes in this tutorial, configure the server's primary and second
260250

261251
Now, test the firewall to confirm that it works as expected.
262252

263-
1. Connect a remote desktop to firewall public IP address and sign in to the **Srv-Work** virtual machine.
253+
1. Connect a remote desktop to firewall public IP address (fw-pip) and sign in to the **Srv-Work** virtual machine.
264254
3. Open Internet Explorer and browse to `https://www.google.com`.
265255
4. Select **OK** > **Close** on the Internet Explorer security alerts.
266256

267257
You should see the Google home page.
268258

269-
5. Browse to `https://www.microsoft.com`.
259+
5. Browse to `http://www.microsoft.com`.
270260

271261
You should be blocked by the firewall.
272262

273263
So now you've verified that the firewall rules are working:
274264

265+
* You can connect a remote desktop to the Srv-Work virtual machine.
275266
* You can browse to the one allowed FQDN, but not to any others.
276267
* You can resolve DNS names using the configured external DNS server.
277268

278269
## Clean up resources
279270

280-
You can keep your firewall resources for the next tutorial, or if no longer needed, delete the **Test-FW-RG** resource group to delete all firewall-related resources.
271+
You can keep your firewall resources for further testing, or if no longer needed, delete the **Test-FW-RG** resource group to delete all firewall-related resources.
281272

282273
## Next steps
283274

0 commit comments

Comments
 (0)