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/search/search-security-enable-roles.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ ms.date: 06/18/2024
14
14
15
15
# Enable or disable role-based access control in Azure AI Search
16
16
17
-
If you want to use Azure role-based access control for connections into Azure AI Search, this article explains how to enable it for your search service.
17
+
If you want to use Azure role assignments for authorized access to Azure AI Search, this article explains how to enable role-based access for your search service.
18
18
19
19
Role-based access for data plane operations is optional, but recommended. The alternative is [key-based authentication](search-security-api-keys.md), which is the default.
20
20
@@ -33,10 +33,10 @@ Roles for service administration (control plane) are built in and can't be enabl
33
33
34
34
When you enable roles for the data plane, the change is effective immediately, but wait a few seconds before assigning roles.
35
35
36
-
The default failure mode is `http401WithBearerChallenge`. Alternatively, you can set the failure mode to `http403`.
37
-
38
36
Once role-based access is enabled, the search service recognizes an **authorization** header on data plane requests that provide an OAuth2 access token.
39
37
38
+
The default failure mode for unauthorized requests is `http401WithBearerChallenge`. Alternatively, you can set the failure mode to `http403`.
39
+
40
40
### [**Azure portal**](#tab/config-svc-portal)
41
41
42
42
1. Sign in to the [Azure portal](https://portal.azure.com) and open the search service page.
Copy file name to clipboardExpand all lines: articles/search/service-configure-firewall.md
+31-11Lines changed: 31 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,30 +10,40 @@ ms.service: cognitive-search
10
10
ms.custom:
11
11
- ignite-2023
12
12
ms.topic: how-to
13
-
ms.date: 06/18/2024
13
+
ms.date: 06/27/2024
14
14
---
15
15
16
16
# Configure network access and firewall rules for Azure AI Search
17
17
18
-
As soon as you install Azure AI Search, you can set up network access to limit access to an approved set of devices and cloud services. There are two mechanisms:
18
+
By default, Azure AI Search is configured to allow connections over a public endpoint. Access to a search service *through* the public endpoint is protected by authentication and authorization protocols, but the endpoint itself is open to the internet at the network layer.
19
+
20
+
If you aren't hosting a public web site, you might want to configure network access to automatically refuse requests unless they originate from an approved set of devices and cloud services. There are two mechanisms:
19
21
20
22
+ Inbound rules listing the IP addresses, ranges, or subnets from which requests are admitted
21
23
+ Exceptions to network rules, where requests are admitted with no checks, as long as the request originates from a [trusted service](#grant-access-to-trusted-azure-services)
22
24
23
-
Network rules aren't required, but it's a security best practice to add them.
25
+
Network rules aren't required, but it's a security best practice to add them if you use Azure AI Search for surfacing private or internal corporate content.
24
26
25
27
Network rules are scoped to data plane operations against the search service's public endpoint. Data plane operations include creating or querying indexes, and all other actions described by the [Search REST APIs](/rest/api/searchservice/). Control plane operations target service administration. Those operations specify resource provider endpoints, which are subject to the [network protections supported by Azure Resource Manager](/security/benchmark/azure/baselines/azure-resource-manager-security-baseline).
26
28
27
29
This article explains how to configure network access to a search service's public endpoint. To block *all* data plane access to the public endpoint, use [private endpoints](service-create-private-endpoint.md) and an Azure virtual network.
28
30
29
-
This article assumes the Azure portal for network access configuration. You can also use the [Management REST API](/rest/api/searchmanagement/), [Azure PowerShell](/powershell/module/az.search), or the [Azure CLI](/cli/azure/search).
31
+
This article assumes the Azure portal to explain network access options. You can also use the [Management REST API](/rest/api/searchmanagement/), [Azure PowerShell](/powershell/module/az.search), or the [Azure CLI](/cli/azure/search).
30
32
31
33
## Prerequisites
32
34
33
35
+ A search service, any region, at the Basic tier or higher
34
36
35
37
+ Owner or Contributor permissions
36
38
39
+
## Limitations
40
+
41
+
There are a few drawbacks to locking down the public endpoint.
42
+
43
+
+ It takes time to fully identify IP ranges and set up firewalls, and if you're in early stages of proof-of-concept testing and investigation and using sample data, you might want to defer network access controls until you actually need them.
44
+
45
+
+ Some workflows require access to a public endpoint. Specifically, the [Import and vectorize data wizard](search-get-started-portal-import-vectors.md) in the Azure portal currently connects to embedding models over the public endpoint, and the response from the embedding model is returned over the public endpoint. You can switch to code or script to complete the same tasks, but if you want to try the wizard, the public endpoint must be available.
46
+
37
47
<aid="configure-ip-policy"></a>
38
48
39
49
## Configure network access in Azure portal
@@ -109,27 +119,37 @@ A banner informs you that IP rules affect the portal experience. This banner rem
109
119
110
120
## Grant access to trusted Azure services
111
121
112
-
Did you select the trusted services exception? If yes, your Azure resource must have a managed identity (either system or user-assigned, but usually system), and you must use role-based access controls.
122
+
Did you select the trusted services exception? If yes, your search service admits requests and responses from a trusted Azure resource without checking for an IP address. A trusted resource must have a managed identity (either system or user-assigned, but usually system). A trusted resource must have a role assignment on Azure AI Search that gives it permission to data and operations.
113
123
114
124
The trusted service list for Azure AI Search includes:
115
125
116
126
+`Microsoft.CognitiveServices` for Azure OpenAI and Azure AI services
117
127
+`Microsoft.MachineLearningServices` for Azure Machine Learning
118
128
119
-
Workflows for this network exception are requests originating *from* Azure AI Studio, Azure OpenAI Studio, or other AML features *to* Azure AI Search, typically in [Azure OpenAI On Your Data](/azure/ai-services/openai/concepts/use-your-data) scenarios for retrieval augmented generation (RAG) and playground environments.
129
+
Workflows for this network exception are requests originating *from* Azure AI Studio, Azure OpenAI Studio, or other AML features *to* Azure AI Search, typically in [Azure OpenAI On Your Data](/azure/ai-services/openai/concepts/use-your-data) scenarios for retrieval augmented generation (RAG) and playground environments.
120
130
121
-
For managed identities on Azure OpenAI and Azure Machine Learning:
131
+
### Trusted resources must have a managed identity
132
+
133
+
To set up managed identities for Azure OpenAI and Azure Machine Learning:
122
134
123
135
+[How to configure Azure OpenAI Service with managed identities](/azure/ai-services/openai/how-to/managed-identity)
124
136
+[How to set up authentication between Azure Machine Learning and other services](/azure/machine-learning/how-to-identity-based-service-authentication).
125
137
126
-
For managed identities on Azure AI services:
138
+
To set up a managed identity for an Azure AI service:
127
139
128
140
1.[Find your multiservice account](https://portal.azure.com/#blade/HubsExtension/BrowseResourceBlade/resourceType/microsoft.cognitiveServices%2Faccounts).
129
141
1. On the leftmost pane, under **Resource management**, select **Identity**.
130
142
1. Set **System-assigned** to **On**.
131
143
132
-
Once your Azure resource has a managed identity, [assign roles on Azure AI Search](search-security-rbac.md) to grant permissions to data and operations. We recommend Search Index Data Reader.
144
+
### Trusted resources must have a role assignment
145
+
146
+
Once your Azure resource has a managed identity, [assign roles on Azure AI Search](keyless-connections.md) to grant permissions to data and operations.
147
+
148
+
The trusted services are used for vectorization workloads: generating vectors from text and image content, and sending payloads back to the search service for query execution or indexing. Connections from a trusted service are used to deliver payloads to Azure AI search.
149
+
150
+
+ To load a search index with vectors generated by an embedding model, assign **Search Index Data Contributor**.
151
+
152
+
+ To provide queries with a vector generated by an embedding model, assign **Search Index Data Reader**. The embedding used in a query isn't written to an index, so no write permissions are required.
133
153
134
154
> [!NOTE]
135
155
> This article covers the trusted exception for admitting requests to your search service, but Azure AI Search is itself on the trusted services list of other Azure resources. Specifically, you can use the trusted service exception for [connections from Azure AI Search to Azure Storage](search-indexer-howto-access-trusted-service-exception.md).
@@ -138,9 +158,9 @@ Once your Azure resource has a managed identity, [assign roles on Azure AI Searc
138
158
139
159
Once a request is allowed through the firewall, it must be authenticated and authorized. You have two options:
140
160
141
-
+[Key-based authentication](search-security-api-keys.md), where an admin or query API key is provided on the request. This is the default.
161
+
+[Key-based authentication](search-security-api-keys.md), where an admin or query API key is provided on the request. This option is the default.
142
162
143
-
+[Role-based access control (RBAC)](search-security-rbac.md) using Microsoft Entra ID, where the caller is a member of a security role on a search service. This is the most secure option. It uses Microsoft Entra ID for authentication and role assignments on Azure AI Search for permissions to data and operations.
163
+
+[Role-based access control](search-security-rbac.md) using Microsoft Entra ID, where the caller is a member of a security role on a search service. This is the most secure option. It uses Microsoft Entra ID for authentication and role assignments on Azure AI Search for permissions to data and operations.
144
164
145
165
> [!div class="nextstepaction"]
146
166
> [Enable RBAC on your search service](search-security-enable-roles.md)
0 commit comments