Skip to content

Commit 3010c1a

Browse files
committed
Added list of clients supporting rbac
1 parent b214a94 commit 3010c1a

File tree

1 file changed

+17
-7
lines changed

1 file changed

+17
-7
lines changed

articles/search/search-security-rbac.md

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ author: HeidiSteen
88
ms.author: heidist
99
ms.service: cognitive-search
1010
ms.topic: how-to
11-
ms.date: 01/12/2023
11+
ms.date: 01/26/2023
1212
ms.custom: subject-rbac-steps, references_regions
1313
---
1414

@@ -52,11 +52,19 @@ Built-in roles include generally available and preview roles. If these roles are
5252

5353
+ In rare cases where requests originate from a high number of different service principals, all targeting different service resources (indexes, indexers, etc.), it's possible for the authorization checks to result in throttling. Throttling would only happen if hundreds of unique combinations of search service resource and service principal were used within a second.
5454

55+
+ Role-based access control is supported in Azure portal and in the following search clients:
56+
57+
+ [Search REST APIs](/rest/api/searchservice/) (all supported versions)
58+
+ [azure.search.documents (Azure SDK for .NET) version 11.4](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/search/Azure.Search.Documents/CHANGELOG.md)
59+
+ [azure.search.documents (Azure SDK for Python) version 11.3](https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/search/azure-search-documents/CHANGELOG.md)
60+
+ [azure-search-documents (Azure SDK for Java) beta versions of 11.5 and 11.6](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/search/azure-search-documents/CHANGELOG.md),
61+
+ [@azure/search-documents (Azure SDK for JavaScript), version 11.3 (see change log)](https://www.npmjs.com/package/@azure/search-documents?activeTab=explore).
62+
5563
## Configure role-based access for data plane
5664

5765
**Applies to:** Search Index Data Contributor, Search Index Data Reader, Search Service Contributor
5866

59-
In this step, configure your search service to recognize an **authorization** header on data requests that provide an OAuth2 access token.
67+
In this step, configure your search service to recognize an **authorization** header on data requests that provide an OAuth2 access token.
6068

6169
### [**Azure portal**](#tab/config-svc-portal)
6270

@@ -71,9 +79,11 @@ In this step, configure your search service to recognize an **authorization** he
7179
| Option | Status | Description |
7280
|--------|--------|-------------|
7381
| API Key | Generally available (default) | Requires an [admin or query API keys](search-security-api-keys.md) on the request header for authorization. No roles are used. |
74-
| Role-based access control | Preview | Requires membership in a role assignment to complete the task, described in the next step. It also requires an authorization header. Choosing this option limits you to clients that support the [2021-04-30-preview REST API](/rest/api/searchservice/index-preview). |
82+
| Role-based access control | Preview | Requires membership in a role assignment to complete the task, described in the next step. It also requires an authorization header. |
7583
| Both | Preview | Requests are valid using either an API key or role-based access control. |
7684

85+
Once you make a request, it can take a few minutes for the change to take effect.
86+
7787
All network calls for search service operations and content will respect the option you select: API keys, bearer token, or either one if you select **Both**.
7888

7989
When you enable role-based access control in the portal, the failure mode will be "http401WithBearerChallenge" if authorization fails. Use the Management REST API to update the service if you want to use "http403" instead.
@@ -82,7 +92,7 @@ When you enable role-based access control in the portal, the failure mode will b
8292

8393
Use the Management REST API version 2021-04-01-Preview, [Create or Update Service](/rest/api/searchmanagement/2021-04-01-preview/services/create-or-update), to configure your service.
8494

85-
If you're using Postman or another REST client, see [Manage Azure Cognitive Search using REST](search-manage-rest.md) for help with setting up the client.
95+
All calls to the Management REST API are authenticated through Azure Active Directory, with Contributor or Owner permissions. For help setting up authenticated requests in Postman, see [Manage Azure Cognitive Search using REST](search-manage-rest.md).
8696

8797
1. Under "properties", set ["AuthOptions"](/rest/api/searchmanagement/2021-04-01-preview/services/create-or-update#dataplaneauthoptions) to "aadOrApiKey".
8898

@@ -278,10 +288,10 @@ This approach assumes Postman as the REST client and uses a Postman collection a
278288
279289
1. Save the collection.
280290
281-
1. Send a request that uses the variables you've specified. For the "Search Index Data Reader" role, you can query an index (remember to provide a valid search service name on the URI):
291+
1. Send a request that uses the variables you've specified. For the "Search Index Data Reader" role, you can query an index (remember to provide a valid search service name on the URI). You can use any [supported API version](/rest/api/searchservice/search-service-api-versions).
282292
283293
```http
284-
POST https://<service-name>.search.windows.net/indexes/hotels-quickstart/docs/search?api-version=2020-06-20
294+
POST https://<service-name>.search.windows.net/indexes/hotels-quickstart/docs/search?api-version=2020-06-30
285295
{
286296
"queryType": "simple",
287297
"search": "motel",
@@ -297,7 +307,7 @@ For more information on how to acquire a token for a specific environment, see [
297307

298308
See [Authorize access to a search app using Azure Active Directory](/search-howto-aad.md) for instructions that create an identity for your client app, assign a role, and call [DefaultAzureCredential()](/dotnet/api/azure.identity.defaultazurecredential).
299309

300-
The Azure SDK for .NET supports an authorization header in the [NuGet Gallery | Azure.Search.Documents 11.4.0-beta.2](https://www.nuget.org/packages/Azure.Search.Documents/11.4.0-beta.2) package. Configuration is required to register an application with Azure Active Directory, and to obtain and pass authorization tokens:
310+
The Azure SDK for .NET supports an authorization header in the [NuGet Gallery | Azure.Search.Documents 11.4.0](https://www.nuget.org/packages/Azure.Search.Documents/11.4.0) package. Configuration is required to register an application with Azure Active Directory, and to obtain and pass authorization tokens:
301311

302312
+ When obtaining the OAuth token, the scope is "https://search.azure.com/.default". The SDK requires the audience to be "https://search.azure.com". The ".default" is an Azure AD convention.
303313

0 commit comments

Comments
 (0)