Skip to content

Commit 3e709df

Browse files
committed
Event Hubs security articles: steps & screenshots
1 parent 637ee42 commit 3e709df

File tree

4 files changed

+49
-38
lines changed

4 files changed

+49
-38
lines changed

articles/event-hubs/event-hubs-ip-filtering.md

Lines changed: 41 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Azure Event Hubs Firewall Rules | Microsoft Docs
33
description: Use Firewall Rules to allow connections from specific IP addresses to Azure Event Hubs.
44
ms.topic: article
5-
ms.date: 02/23/2022
5+
ms.date: 02/15/2023
66
---
77

88
# Allow access to Azure Event Hubs namespaces from specific IP addresses or ranges
@@ -25,20 +25,16 @@ This section shows you how to use the Azure portal to create IP firewall rules f
2525

2626
1. Navigate to your **Event Hubs namespace** in the [Azure portal](https://portal.azure.com).
2727
4. Select **Networking** under **Settings** on the left menu.
28-
1. On the **Networking** page, for **Public network access**, you can set one of the three following options. Choose **Selected networks** option to allow access from only specified IP addresses.
28+
1. On the **Networking** page, for **Public network access**, choose **Selected networks** option to allow access from only specified IP addresses.
29+
30+
Here are more details about options available in the **Public network access** page:
2931
- **Disabled**. This option disables any public access to the namespace. The namespace will be accessible only through [private endpoints](private-link-service.md).
30-
31-
:::image type="content" source="./media/event-hubs-firewall/public-access-disabled.png" alt-text="Networking page - public access tab - public network access is disabled.":::
3232
- **Selected networks**. This option enables public access to the namespace using an access key from selected networks.
3333

3434
> [!IMPORTANT]
35-
> If you choose **Selected networks**, add at least one IP firewall rule or a virtual network that will have access to the namespace. Choose **Disabled** if you want to restrict all traffic to this namespace over [private endpoints](private-link-service.md) only.
36-
37-
:::image type="content" source="./media/event-hubs-firewall/selected-networks.png" alt-text="Networking page with the selected networks option selected." lightbox="./media/event-hubs-firewall/selected-networks.png":::
35+
> If you choose **Selected networks**, add at least one IP firewall rule or a virtual network that will have access to the namespace. Choose **Disabled** if you want to restrict all traffic to this namespace over [private endpoints](private-link-service.md) only.
3836
- **All networks** (default). This option enables public access from all networks using an access key. If you select the **All networks** option, the event hub accepts connections from any IP address (using the access key). This setting is equivalent to a rule that accepts the 0.0.0.0/0 IP address range.
39-
40-
:::image type="content" source="./media/event-hubs-firewall/firewall-all-networks-selected.png" lightbox="./media/event-hubs-firewall/firewall-all-networks-selected.png" alt-text="Screenshot that shows the Public access page with the All networks option selected.":::
41-
1. To restrict access to **specific IP addresses**, follow these steps:
37+
1. To restrict access to **specific IP addresses**, select **Selected networks** option, and then follow these steps:
4238
1. In the **Firewall** section, select **Add your client IP address** option to give your current client IP the access to the namespace.
4339
3. For **address range**, enter a specific IPv4 address or a range of IPv4 address in CIDR notation.
4440

@@ -71,56 +67,79 @@ The following Resource Manager template enables adding an IP filter rule to an e
7167
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
7268
"contentVersion": "1.0.0.0",
7369
"parameters": {
74-
"eventhubNamespaceName": {
70+
"namespace_name": {
71+
"defaultValue": "contosoehub1333",
7572
"type": "String"
7673
}
7774
},
75+
"variables": {},
7876
"resources": [
7977
{
8078
"type": "Microsoft.EventHub/namespaces",
81-
"apiVersion": "2021-11-01",
82-
"name": "[parameters('eventhubNamespaceName')]",
79+
"apiVersion": "2022-01-01-preview",
80+
"name": "[parameters('namespace_name')]",
8381
"location": "East US",
8482
"sku": {
8583
"name": "Standard",
8684
"tier": "Standard",
8785
"capacity": 1
8886
},
8987
"properties": {
88+
"minimumTlsVersion": "1.2",
89+
"publicNetworkAccess": "Enabled",
9090
"disableLocalAuth": false,
9191
"zoneRedundant": true,
9292
"isAutoInflateEnabled": false,
9393
"maximumThroughputUnits": 0,
9494
"kafkaEnabled": true
9595
}
9696
},
97+
{
98+
"type": "Microsoft.EventHub/namespaces/authorizationrules",
99+
"apiVersion": "2022-01-01-preview",
100+
"name": "[concat(parameters('namespaces_spehubns0215_name'), '/RootManageSharedAccessKey')]",
101+
"location": "eastus",
102+
"dependsOn": [
103+
"[resourceId('Microsoft.EventHub/namespaces', parameters('namespaces_spehubns0215_name'))]"
104+
],
105+
"properties": {
106+
"rights": [
107+
"Listen",
108+
"Manage",
109+
"Send"
110+
]
111+
}
112+
},
97113
{
98114
"type": "Microsoft.EventHub/namespaces/networkRuleSets",
99-
"apiVersion": "2021-11-01",
100-
"name": "[concat(parameters('eventhubNamespaceName'), '/default')]",
115+
"apiVersion": "2022-01-01-preview",
116+
"name": "[concat(parameters('namespaces_spehubns0215_name'), '/default')]",
101117
"location": "East US",
102118
"dependsOn": [
103-
"[resourceId('Microsoft.EventHub/namespaces', parameters('eventhubNamespaceName'))]"
119+
"[resourceId('Microsoft.EventHub/namespaces', parameters('namespaces_spehubns0215_name'))]"
104120
],
105121
"properties": {
106122
"publicNetworkAccess": "Enabled",
107123
"defaultAction": "Deny",
108124
"virtualNetworkRules": [],
109125
"ipRules": [
110126
{
111-
"ipMask":"10.1.1.1",
112-
"action":"Allow"
127+
"ipMask": "10.1.1.1",
128+
"action": "Allow"
113129
},
114130
{
115-
"ipMask":"11.0.0.0/24",
116-
"action":"Allow"
117-
}
131+
"ipMask": "11.0.0.0/24",
132+
"action": "Allow"
133+
},
134+
{
135+
"ipMask": "172.72.157.204",
136+
"action": "Allow"
137+
}
118138
]
119139
}
120140
}
121141
]
122142
}
123-
124143
```
125144

126145
To deploy the template, follow the instructions for [Azure Resource Manager][lnk-deploy].

articles/event-hubs/event-hubs-service-endpoints.md

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Virtual Network service endpoints - Azure Event Hubs | Microsoft Docs
33
description: This article provides information on how to add a Microsoft.EventHub service endpoint to a virtual network.
44
ms.topic: article
5-
ms.date: 02/23/2021
5+
ms.date: 02/15/2023
66
---
77

88
# Allow access to Azure Event Hubs namespaces from specific virtual networks
@@ -40,18 +40,14 @@ This section shows you how to use Azure portal to add a virtual network service
4040
1. Navigate to your **Event Hubs namespace** in the [Azure portal](https://portal.azure.com).
4141
4. Select **Networking** under **Settings** on the left menu.
4242
1. On the **Networking** page, for **Public network access**, you can set one of the three following options. Choose **Selected networks** option to allow access only from specific virtual networks.
43+
44+
Here are more details about options available in the **Public network access** page:
4345
- **Disabled**. This option disables any public access to the namespace. The namespace will be accessible only through [private endpoints](private-link-service.md).
44-
45-
:::image type="content" source="./media/event-hubs-firewall/public-access-disabled.png" alt-text="Networking page - public access tab - public network access is disabled.":::
4646
- **Selected networks**. This option enables public access to the namespace using an access key from selected networks.
4747

4848
> [!IMPORTANT]
49-
> If you choose **Selected networks**, add at least one IP firewall rule or a virtual network that will have access to the namespace. Choose **Disabled** if you want to restrict all traffic to this namespace over [private endpoints](private-link-service.md) only.
50-
51-
:::image type="content" source="./media/event-hubs-firewall/selected-networks.png" alt-text="Networking page with the selected networks option selected." lightbox="./media/event-hubs-firewall/selected-networks.png":::
49+
> If you choose **Selected networks**, add at least one IP firewall rule or a virtual network that will have access to the namespace. Choose **Disabled** if you want to restrict all traffic to this namespace over [private endpoints](private-link-service.md) only.
5250
- **All networks** (default). This option enables public access from all networks using an access key. If you select the **All networks** option, the event hub accepts connections from any IP address (using the access key). This setting is equivalent to a rule that accepts the 0.0.0.0/0 IP address range.
53-
54-
:::image type="content" source="./media/event-hubs-firewall/firewall-all-networks-selected.png" lightbox="./media/event-hubs-firewall/firewall-all-networks-selected.png" alt-text="Screenshot that shows the Public access page with the All networks option selected.":::
5551
1. To restrict access to specific networks, choose the **Selected Networks** option at the top of the page if it isn't already selected.
5652
2. In the **Virtual networks** section of the page, select **+Add existing virtual network***. Select **+ Create new virtual network** if you want to create a new VNet.
5753

-8.14 KB
Loading

articles/event-hubs/private-link-service.md

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Integrate Azure Event Hubs with Azure Private Link Service
33
description: Learn how to integrate Azure Event Hubs with Azure Private Link Service
4-
ms.date: 08/26/2022
4+
ms.date: 02/15/2023
55
ms.topic: article
66
ms.custom: devx-track-azurepowershell
77
---
@@ -40,18 +40,14 @@ If you already have an Event Hubs namespace, you can create a private link conne
4040
2. In the search bar, type in **event hubs**.
4141
3. Select the **namespace** from the list to which you want to add a private endpoint.
4242
1. On the **Networking** page, for **Public network access**, you can set one of the three following options. Select **Disabled** if you want the namespace to be accessed only via private endpoints.
43+
44+
Here are more details about options available in the **Public network access** page:
4345
- **Disabled**. This option disables any public access to the namespace. The namespace will be accessible only through [private endpoints](private-link-service.md).
44-
45-
:::image type="content" source="./media/event-hubs-firewall/public-access-disabled.png" alt-text="Networking page - public access tab - public network access is disabled.":::
4646
- **Selected networks**. This option enables public access to the namespace using an access key from selected networks.
4747

4848
> [!IMPORTANT]
49-
> If you choose **Selected networks**, add at least one IP firewall rule or a virtual network that will have access to the namespace. Choose **Disabled** if you want to restrict all traffic to this namespace over [private endpoints](private-link-service.md) only.
50-
51-
:::image type="content" source="./media/event-hubs-firewall/selected-networks.png" alt-text="Networking page with the selected networks option selected." lightbox="./media/event-hubs-firewall/selected-networks.png":::
49+
> If you choose **Selected networks**, add at least one IP firewall rule or a virtual network that will have access to the namespace. Choose **Disabled** if you want to restrict all traffic to this namespace over [private endpoints](private-link-service.md) only.
5250
- **All networks** (default). This option enables public access from all networks using an access key. If you select the **All networks** option, the event hub accepts connections from any IP address (using the access key). This setting is equivalent to a rule that accepts the 0.0.0.0/0 IP address range.
53-
54-
:::image type="content" source="./media/event-hubs-firewall/firewall-all-networks-selected.png" lightbox="./media/event-hubs-firewall/firewall-all-networks-selected.png" alt-text="Screenshot that shows the Public access page with the All networks option selected.":::
5551
1. Switch to the **Private endpoint connections** tab.
5652
1. Select the **+ Private Endpoint** button at the top of the page.
5753

0 commit comments

Comments
 (0)