Skip to content

Commit d3b346f

Browse files
Merge pull request #311174 from spelluru/ehubnsp0130
Network security perimeter - Azure Event Hubs
2 parents 6d59e44 + 647cad1 commit d3b346f

9 files changed

Lines changed: 180 additions & 18 deletions

articles/event-hubs/TOC.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -339,6 +339,8 @@
339339
href: event-hubs-service-endpoints.md
340340
- name: Allow access via private endpoints
341341
href: private-link-service.md
342+
- name: Associate a network security perimeter
343+
href: associate-network-security-perimeter.md
342344
- name: Encrypt data using customer-managed keys
343345
href: configure-customer-managed-key.md
344346
- name: Configure minimum required TLS version
Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
---
2+
title: Associate Network Security Perimeter With Event Hubs
3+
description: Discover step-by-step instructions to associate a network security perimeter with your Azure Event Hubs namespace and secure your data streams.
4+
#customer intent: As an IT professional, I want to verify the association of a network security perimeter with my Event Hubs namespace so that I can ensure proper configuration.
5+
ms.topic: how-to
6+
ms.date: 01/31/2026
7+
---
8+
9+
# Associate network security perimeter (NSP) with an Azure Event Hubs namespace
10+
11+
You can associate a network security perimeter (NSP) with an Azure Event Hubs namespace to enhance the security of your event streaming infrastructure. This association restricts access to the Event Hubs namespace based on the defined security perimeter, allowing you to:
12+
13+
- Control which Azure resources can communicate with your Event Hubs namespace.
14+
- Define inbound and outbound access rules for your event streaming workloads.
15+
- Monitor and audit network access to your Event Hubs resources.
16+
17+
> [!NOTE]
18+
> For conceptual information, see [Network security perimeter for Azure Event Hubs](network-security-perimeter.md).
19+
20+
## Prerequisites
21+
22+
Before you begin, ensure you have the following prerequisites in place:
23+
24+
- An existing Azure Event Hubs namespace.
25+
- An existing network security perimeter (NSP) in your Azure subscription. If you don't have one, [create a network security perimeter](/azure/private-link/create-network-security-perimeter-portal) first.
26+
- A profile configured within the NSP to associate with your Event Hubs namespace.
27+
- The **Contributor** role or higher on the Event Hubs namespace.
28+
- The **Network Security Perimeter Contributor** role or higher on the NSP.
29+
30+
## Associate NSP with an Azure Event Hubs namespace
31+
32+
Follow these steps to associate an NSP with your Event Hubs namespace using the Azure portal:
33+
34+
1. Sign in to the [Azure portal](https://portal.azure.com/).
35+
1. In the search box, enter **Event Hubs**, and then select **Event Hubs** from the search results.
36+
1. Select your Event Hubs namespace from the list.
37+
1. In the left-hand menu under **Settings**, select **Networking**.
38+
1. Select the **Public access** tab.
39+
1. Under the **Network security perimeter** section, select **Associate NSP**.
40+
41+
:::image type="content" source="./media/associate-network-security-perimeter/associate-button.png" alt-text="Screenshot of the Networking page with Associate button for network security perimeter selected." lightbox="./media/associate-network-security-perimeter/associate-button.png":::
42+
1. In the **Associate network security perimeter** page, complete the following configuration:
43+
44+
| Setting | Description |
45+
| --- | --- |
46+
| **Network security perimeter** | Select the NSP you want to associate from the dropdown list. Only NSPs in the same region as your Event Hubs namespace are available. |
47+
| **Profile** | Select the profile within the NSP to associate with the Event Hubs namespace. Profiles contain the access rules that apply to associated resources. |
48+
49+
1. Select **Associate** to complete the association.
50+
51+
:::image type="content" source="./media/associate-network-security-perimeter/associate-network-security-perimeter-page.png" alt-text="Screenshot of the Associate a network security perimeter page." lightbox="./media/associate-network-security-perimeter/associate-network-security-perimeter-page.png":::
52+
53+
1. Wait for the association to complete. The process typically takes a few minutes.
54+
1. Once the association is complete, verify that the NSP appears under the **Network security perimeter** section of your Event Hubs namespace.
55+
56+
:::image type="content" source="./media/associate-network-security-perimeter/public-access-page.png" alt-text="Screenshot of the Public access page with the network security perimeter selected." lightbox="./media/associate-network-security-perimeter/public-access-page.png":::
57+
58+
## Manage NSP settings
59+
60+
After associating the NSP with your Event Hubs namespace, you can manage and configure the security settings.
61+
62+
### View and modify NSP configuration
63+
64+
1. On the **Networking** page of your Event Hubs namespace, select **Manage** in the **Network security perimeter** section.
65+
66+
:::image type="content" source="./media/associate-network-security-perimeter/manage-button.png" alt-text="Screenshot of the Public access page with Manage button highlighted in the network security perimeter section." lightbox="./media/associate-network-security-perimeter/manage-button.png":::
67+
68+
1. Review the inbound and outbound access rules configured for the NSP. These rules determine what traffic is allowed to and from your Event Hubs namespace.
69+
70+
:::image type="content" source="./media/associate-network-security-perimeter/associate-inbound-outbound-rules.png" alt-text="Screenshot of the Network security perimeter configuration page." lightbox="./media/associate-network-security-perimeter/associate-inbound-outbound-rules.png":::
71+
1. To add or modify inbound and outbound rules:
72+
1. Navigate to the NSP configuration page by selecting the **NSP name** at the top of the page.
73+
1. In the NSP configuration, you can:
74+
- Add **inbound access rules** to allow specific external resources or IP addresses to access your Event Hubs namespace.
75+
- Add **outbound access rules** to allow your Event Hubs namespace to communicate with external resources.
76+
- Modify or delete existing rules as needed.
77+
78+
> [!TIP]
79+
> When configuring access rules, follow the principle of least privilege by only allowing the minimum required access for your workloads.
80+
81+
### Assign a managed identity
82+
83+
To use managed identity with your NSP-associated Event Hubs namespace:
84+
85+
1. In the **Associate resource** section, select **Manage** for **Identity**.
86+
87+
:::image type="content" source="./media/associate-network-security-perimeter/assign-managed-identity-link.png" alt-text="Screenshot of the Network security perimeter configuration page with the Manage button for the Identity is highlighted." lightbox="./media/associate-network-security-perimeter/assign-managed-identity-link.png":::
88+
89+
1. Follow the steps in [Enable managed identity for Event Hubs](enable-managed-identity.md) to assign a system-assigned or user-assigned managed identity to your namespace.
90+
91+
## Verify the association
92+
93+
After completing the association, perform these verification steps:
94+
95+
1. **Test connectivity**: Verify that the Event Hubs namespace is accessible only from resources within the defined network security perimeter.
96+
- Attempt to connect from a resource inside the perimeter (should succeed).
97+
- Attempt to connect from a resource outside the perimeter (should be blocked unless allowed by access rules).
98+
1. **Review diagnostic logs**: Enable diagnostic logging for your Event Hubs namespace to monitor connection attempts and identify any access issues.
99+
1. **Validate application functionality**: Ensure that your applications can still send and receive events as expected.
100+
101+
## Best practices
102+
103+
Follow these best practices when using NSP with Event Hubs:
104+
105+
- **Plan your perimeter**: Before you associate an NSP, map out all the resources that need to communicate with your Event Hubs namespace.
106+
- **Use profiles effectively**: Create separate profiles for different environments (development, staging, production) to apply appropriate access rules.
107+
- **Monitor regularly**: Set up alerts and regularly review access logs to detect unauthorized access attempts.
108+
- **Keep rules updated**: As your infrastructure changes, update your NSP rules to reflect new requirements while maintaining security.
109+
- **Test changes**: Before applying NSP changes in production, test them in a nonproduction environment.
110+
111+
## Troubleshooting
112+
113+
If you encounter issues after associating an NSP with your Event Hubs namespace:
114+
115+
| Issue | Possible cause | Solution |
116+
| --- | --- | --- |
117+
| Applications can't connect to Event Hubs | NSP is blocking the traffic | Add an inbound access rule to allow traffic from your application's network. |
118+
| Event Hubs can't send data to downstream services | Outbound rules are too restrictive | Add an outbound access rule to allow traffic to the required destination. |
119+
| NSP doesn't appear in the dropdown list | NSP is in a different region | Create an NSP in the same region as your Event Hubs namespace. |
120+
| Association fails | Insufficient permissions | Verify you have the required roles on both the Event Hubs namespace and the NSP. |
121+
122+
## Related content
123+
124+
- [Network security perimeter for Azure Event Hubs](network-security-perimeter.md)
125+
- [Azure network security perimeter concepts](/azure/private-link/network-security-perimeter-concepts)
126+
- [Create a network security perimeter](/azure/private-link/create-network-security-perimeter-portal)
190 KB
Loading
263 KB
Loading
188 KB
Loading
80.2 KB
Loading
117 KB
Loading
268 KB
Loading
Lines changed: 52 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,69 @@
11
---
22
title: Network Security Perimeter
33
titleSuffix: Azure Event Hubs
4-
description: Overview of Network Security Perimeter feature for Event Hubs
4+
description: Learn how Network Security Perimeter (NSP) enhances security for Azure Event Hubs by controlling network access between PaaS services.
55
ms.reviewer: spelluru
6-
ms.date: 12/16/2025
6+
ms.date: 01/31/2026
77
ms.topic: conceptual
88
ms.custom:
99
---
1010

1111

1212
# Network Security Perimeter for Azure Event Hubs
1313

14-
[Event Hubs](./event-hubs-about.md)
14+
Network Security Perimeter (NSP) is a network isolation feature that enables you to define a logical network boundary for Platform as a Service (PaaS) resources, including Azure Event Hubs. It restricts public network access to resources within the perimeter while allowing secure communication between associated PaaS services.
1515

16-
The Network Security Perimeter serves as a crucial safeguard for network traffic between Azure Event Hubs and other Platform as a Service (PaaS) offerings like Azure Storage and Azure Key Vault. By confining communication solely to Azure resources within its boundaries, it effectively blocks unauthorized attempts to access resources beyond its secure perimeter.
16+
## Overview
1717

18-
Integrating Event Hubs Kafka within this framework enhances data streaming capabilities while ensuring robust security measures. This integration not only provides a reliable and scalable platform but also strengthens data protection strategies, mitigating risks associated with unauthorized access or data breaches.
18+
Network Security Perimeter provides an extra layer of security for your Azure Event Hubs namespace by:
1919

20-
Operating as a service under Azure Private Link, the Network Security Perimeter facilitates secure communication for PaaS services deployed outside the virtual network. It enables seamless interaction among PaaS services within the perimeter and facilitates communication with external resources through carefully configured access rules. Additionally, it supports outbound resources such as Azure Key Vault for Bring Your Own Key (BYOK) and Azure Storage for data capture, further enhancing its versatility and utility in diverse cloud environments.
20+
- **Restricting public access**: By default, resources within the perimeter are protected from unauthorized external access.
21+
- **Enabling secure PaaS-to-PaaS communication**: Event Hubs can securely communicate with other Azure services like Azure Storage and Azure Key Vault within the same perimeter.
22+
- **Simplifying network security management**: Instead of managing individual service firewalls, you can define access rules at the perimeter level.
23+
- **Supporting compliance requirements**: NSP helps meet regulatory requirements by providing clear network boundaries for your data.
2124

22-
> [!NOTE]
23-
> - Network Security Perimeter does not support [Azure Event Hubs - Geo-disaster recovery](./event-hubs-geo-dr.md)
24-
> - Certain Network Security Perimeter features such as same perimeter access, cross perimeter access, and subscription access rules don’t work with Shared Access Signature authentication "
25+
Operating as a service under Azure Private Link, Network Security Perimeter facilitates secure communication for PaaS services deployed outside the virtual network. It supports:
2526

26-
## Associate Event Hubs with a Network Security Perimeter in the Azure portal
27-
1. Search for "Network Security Perimeter" in the Portal search bar and then click on **Create** button and create the resource.
28-
1. In the first screen, provide a Name and Region and choose the subscription.
29-
1. Under the **Resources** section, click on the **Associate** button and navigate to the Event Hubs namespace you want to add.
27+
- Seamless interaction among PaaS services within the perimeter
28+
- Communication with external resources through carefully configured access rules
29+
- Outbound access to services such as Azure Key Vault for Bring Your Own Key (BYOK) encryption and Azure Storage for Event Hubs Capture
3030

31-
## Related Content
32-
- For an overview of [network service perimeter](../private-link/network-security-perimeter-concepts.md)
33-
- For monitoring with [diagnostic logs in network security perimeter](../private-link/network-security-perimeter-concepts.md)
34-
- For other Event Hubs security features, see [Network Security for Azure Event Hubs](./network-security.md)
35-
- For additional information on using private endpoints, see [Use Private Endpoints](./private-link-service.md)
31+
## Key capabilities
32+
33+
When you associate an Event Hubs namespace with a Network Security Perimeter, you gain the following capabilities:
34+
35+
| Capability | Description |
36+
| --- | --- |
37+
| **Inbound access rules** | Control which external resources, IP addresses, or subscriptions can send data to your Event Hubs namespace. |
38+
| **Outbound access rules** | Define which external resources your Event Hubs namespace can communicate with (for example, storage accounts for Capture). |
39+
| **Profile-based management** | Apply different access rule sets to different resources using NSP profiles. |
40+
| **Diagnostic logging** | Monitor network access attempts and audit security events through NSP diagnostic logs. |
41+
42+
## Supported scenarios
43+
44+
Network Security Perimeter for Event Hubs supports the following scenarios:
45+
46+
- **Event ingestion from Azure services**: Allow other Azure services within the same perimeter to send events to your Event Hubs namespace.
47+
- **Kafka workloads**: Integrating Event Hubs with Kafka within the NSP framework enhances data streaming capabilities while maintaining robust security.
48+
- **Data capture**: Configure outbound rules to allow Event Hubs to write captured data to Azure Storage or Azure Data Lake Storage.
49+
- **Customer-managed keys**: Enable outbound access to Azure Key Vault for encryption with customer-managed keys (BYOK).
50+
51+
## Limitations
52+
53+
Be aware of the following limitations when using Network Security Perimeter with Event Hubs:
54+
55+
- Network Security Perimeter doesn't support [Azure Event Hubs - Geo-disaster recovery](./event-hubs-geo-dr.md).
56+
- Certain Network Security Perimeter features, such as same perimeter access, cross perimeter access, and subscription access rules, don't work with Shared Access Signature (SAS) authentication. Use Microsoft Entra ID authentication for full NSP functionality.
57+
58+
## Associate Event Hubs with a Network Security Perimeter
59+
60+
To learn how to associate a Network Security Perimeter with your Event Hubs namespace, see [Associate Network Security Perimeter with Event Hubs](associate-network-security-perimeter.md).
61+
62+
## Related content
63+
64+
- [Network security perimeter concepts](/azure/private-link/network-security-perimeter-concepts)
65+
- [Create a network security perimeter](/azure/private-link/create-network-security-perimeter-portal)
66+
- [Diagnostic logs in network security perimeter](/azure/private-link/network-security-perimeter-diagnostic-logs)
67+
- [Network security for Azure Event Hubs](./network-security.md)
68+
- [Use private endpoints with Event Hubs](./private-link-service.md)
69+
- [Configure IP firewall rules](./event-hubs-ip-filtering.md)

0 commit comments

Comments
 (0)