Skip to content

Commit 4899629

Browse files
Merge pull request #275631 from rwike77/quickstartupdate
Update quickstart for External ID
2 parents 367d239 + 44ff733 commit 4899629

13 files changed

+191
-137
lines changed

articles/app-service/configure-authentication-oauth-tokens.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ From your server code, the provider-specific tokens are injected into the reques
1818

1919
| Provider | Header names |
2020
|-|-|
21-
| Microsoft Entra ID | `X-MS-TOKEN-AAD-ID-TOKEN` <br/> `X-MS-TOKEN-AAD-ACCESS-TOKEN` <br/> `X-MS-TOKEN-AAD-EXPIRES-ON` <br/> `X-MS-TOKEN-AAD-REFRESH-TOKEN` |
21+
| Microsoft Entra | `X-MS-TOKEN-AAD-ID-TOKEN` <br/> `X-MS-TOKEN-AAD-ACCESS-TOKEN` <br/> `X-MS-TOKEN-AAD-EXPIRES-ON` <br/> `X-MS-TOKEN-AAD-REFRESH-TOKEN` |
2222
| Facebook Token | `X-MS-TOKEN-FACEBOOK-ACCESS-TOKEN` <br/> `X-MS-TOKEN-FACEBOOK-EXPIRES-ON` |
2323
| Google | `X-MS-TOKEN-GOOGLE-ID-TOKEN` <br/> `X-MS-TOKEN-GOOGLE-ACCESS-TOKEN` <br/> `X-MS-TOKEN-GOOGLE-EXPIRES-ON` <br/> `X-MS-TOKEN-GOOGLE-REFRESH-TOKEN` |
2424
| Twitter | `X-MS-TOKEN-TWITTER-ACCESS-TOKEN` <br/> `X-MS-TOKEN-TWITTER-ACCESS-TOKEN-SECRET` |
@@ -34,7 +34,7 @@ From your client code (such as a mobile app or in-browser JavaScript), send an H
3434
3535
## Refresh auth tokens
3636

37-
When your provider's access token (not the [session token](#extend-session-token-expiration-grace-period)) expires, you need to reauthenticate the user before you use that token again. You can avoid token expiration by making a `GET` call to the `/.auth/refresh` endpoint of your application. When called, App Service automatically refreshes the access tokens in the [token store](overview-authentication-authorization.md#token-store) for the authenticated user. Subsequent requests for tokens by your app code get the refreshed tokens. However, for token refresh to work, the token store must contain [refresh tokens](https://auth0.com/learn/refresh-tokens/) for your provider. The way to get refresh tokens are documented by each provider, but the following list is a brief summary:
37+
When your provider's access token (not the [session token](#extend-session-token-expiration-grace-period)) expires, you need to reauthenticate the user before you use that token again. You can avoid token expiration by making a `GET` call to the `/.auth/refresh` endpoint of your application. When called, App Service automatically refreshes the access tokens in the [token store](overview-authentication-authorization.md#token-store) for the authenticated user. Subsequent requests for tokens by your app code get the refreshed tokens. However, for token refresh to work, the token store must contain [refresh tokens](/entra/identity-platform/refresh-tokens) for your provider. The way to get refresh tokens are documented by each provider, but the following list is a brief summary:
3838

3939
- **Google**: Append an `access_type=offline` query string parameter to your `/.auth/login/google` API call. For more information, see [Google Refresh Tokens](https://developers.google.com/identity/protocols/OpenIDConnect#refresh-tokens).
4040
- **Facebook**: Doesn't provide refresh tokens. Long-lived tokens expire in 60 days (see [Facebook Expiration and Extension of Access Tokens](https://developers.facebook.com/docs/facebook-login/access-tokens/expiration-and-extension)).

articles/app-service/configure-authentication-provider-aad.md

Lines changed: 142 additions & 113 deletions
Large diffs are not rendered by default.

articles/app-service/configure-authentication-user-identities.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ For all language frameworks, App Service makes the claims in the incoming token
2323
| `X-MS-CLIENT-PRINCIPAL-NAME` | A human-readable name for the caller set by the identity provider, e.g. Email Address, User Principal Name. |
2424
| `X-MS-CLIENT-PRINCIPAL-IDP` | The name of the identity provider used by App Service Authentication. |
2525

26-
Provider tokens are also exposed through similar headers. For example, the Microsoft Identity Provider also sets `X-MS-TOKEN-AAD-ACCESS-TOKEN` and `X-MS-TOKEN-AAD-ID-TOKEN` as appropriate.
26+
Provider tokens are also exposed through similar headers. For example, Microsoft Entra also sets `X-MS-TOKEN-AAD-ACCESS-TOKEN` and `X-MS-TOKEN-AAD-ID-TOKEN` as appropriate.
2727

2828
> [!NOTE]
2929
> Different language frameworks may present these headers to the app code in different formats, such as lowercase or title case.

articles/app-service/includes/scenario-secure-app-clean-up-resources.md

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ ms.subservice: web-apps
1515
#Customer intent: As an application developer, I want to learn how to access Azure Storage for an app using managed identities.
1616
---
1717

18-
If you completed all the steps in this multipart tutorial, you created an app service, app service hosting plan, and a storage account in a resource group. You also created an app registration in Microsoft Entra ID. When no longer needed, delete these resources and app registration so that you don't continue to accrue charges.
18+
If you completed all the steps in this multipart tutorial, you created an App Service, App Service hosting plan, and a storage account in a resource group. You also created an app registration in Microsoft Entra ID. If you chose external configuration, you may have created a new external tenant. When no longer needed, delete these resources and app registration so that you don't continue to accrue charges.
1919

2020
In this tutorial, you learn how to:
2121

@@ -25,7 +25,7 @@ In this tutorial, you learn how to:
2525
2626
### Delete the resource group
2727

28-
In the [Azure portal](https://portal.azure.com), select **Resource groups** from the portal menu and select the resource group that contains your app service and app service plan.
28+
In the [Azure portal](https://portal.azure.com), select **Resource groups** from the portal menu and select the resource group that contains your App Service and App Service plan.
2929

3030
Select **Delete resource group** to delete the resource group and all the resources.
3131

@@ -40,3 +40,13 @@ In the [Microsoft Entra admin center](https://entra.microsoft.com), select **App
4040

4141
In the app registration overview, select **Delete**.
4242
:::image type="content" alt-text="Screenshot that shows deleting the app registration." source="../media/scenario-secure-app-clean-up-resources/delete-app-registration.png":::
43+
44+
### Delete the external tenant
45+
46+
If you created a new external tenant, you can [delete it](/entra/external-id/customers/how-to-delete-external-tenant-portal). In to the [Microsoft Entra admin center](https://entra.microsoft.com), browse to **Identity** > **Overview** > **Manage tenants**.
47+
48+
Select the tenant you want to delete, and then select **Delete**.
49+
50+
You might need to complete required actions before you can delete the tenant. For example, you might need to delete all user flows and app registrations in the tenant.
51+
52+
If you're ready to delete the tenant, select **Delete**.

articles/app-service/includes/tutorial-set-up-app-service-authentication/after.md

Lines changed: 28 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ manager: CelesteDG
77

88
ms.service: app-service
99
ms.topic: include
10-
ms.date: 03/12/2024
10+
ms.date: 05/16/2024
1111
ms.author: ryanwi
1212
ms.reviewer: stsoneff
1313
ms.custom: azureday1
@@ -55,11 +55,20 @@ Now that you have a web app running on App Service, enable authentication and au
5555

5656
1. For **App registration** > **App registration type**, select **Create new app registration** to create a new app registration in Microsoft Entra.
5757

58-
1. Add a **Name** for the app registration, a public facing display name.
58+
1. Enter a display **Name** for your application. Users of your application might see the display name when they use the app, for example during sign-in.
5959

6060
1. For **App registration** > **Supported account types**, select **Current tenant-single tenant** so only users in your organization can sign in to the web app.
6161

62-
1. In the **App Service authentication settings** section, leave **Authentication** set to **Require authentication** and **Unauthenticated requests** set to **HTTP 302 Found redirect: recommended for websites**.
62+
1. In the **Additional checks** section, select:
63+
64+
- **Allow requests only from this application itself** for **Client application requirement**
65+
- **Allow requests from any identity** for **Identity requirement**
66+
- **Allow requests only from the issuer tenant** for **Tenant requirement**
67+
68+
1. In the **App Service authentication settings** section, set:
69+
- **Require authentication** for **Authentication**
70+
- **HTTP 302 Found redirect: recommended for websites** for **Unauthenticated requests**
71+
- **Token store** box
6372

6473
1. At the bottom of the **Add an identity provider** page, select **Add** to enable authentication for your web app.
6574

@@ -85,11 +94,17 @@ Now that you have a web app running on App Service, enable authentication and au
8594

8695
1. For **Tenant type**, select **External configuration** for external users.
8796

88-
1. Select **Create new app registration** to create a new app registration and select the [customer (external) tenant](/entra/external-id/customers/quickstart-tenant-setup) you want to use.
97+
1. Select **Create new app registration** to create a new app registration.
8998

90-
1. Select **Configure** to configure external authentication.
99+
1. Select an existing tenant to use from the drop-down, or select **Create new** to create a new [external tenant](/entra/external-id/customers/quickstart-tenant-setup).
100+
101+
:::image type="content" alt-text="Screenshot that shows the Select a tenent dropdown." source="../../media/scenario-secure-app-authentication-app-service/configure-authentication-external-select.png":::
91102

92-
:::image type="content" alt-text="Screenshot that shows the Add an identity provider page." source="../../media/scenario-secure-app-authentication-app-service/configure-authentication-external.png":::
103+
1. (Optional) In the **Create a tenant** page, add the *Tenant Name** and **Domain Name**. Select a **Location** and select **Review and create** and then **Create**.
104+
105+
:::image type="content" alt-text="Screenshot the Create a tenant page." source="../../media/scenario-secure-app-authentication-app-service/configure-authentication-external-create-tenant.png":::
106+
107+
1. Select **Configure** to configure external authentication.
93108

94109
1. The browser opens **Configure customer authentication**. In **Setup sign-in**, select **Create new** to create a sign-in experience for your external users.
95110

@@ -105,15 +120,15 @@ Now that you have a web app running on App Service, enable authentication and au
105120

106121
1. Add your company logo, select a background color, and select a sign-in layout.
107122

108-
:::image type="content" alt-text="Screenshot that shows the customize branding tab." source="../../media/scenario-secure-app-authentication-app-service/configure-authentication-branding.png":::
123+
:::image type="content" alt-text="Screenshot that shows the customized branding tab." source="../../media/scenario-secure-app-authentication-app-service/configure-authentication-branding.png":::
109124

110-
1. Select **Next** and **Yes, update the changes** to accept the branding changes.
125+
1. Select **Next**. If the tenant you selected already has a branding configuration you will need to confirm that you want to override it.
111126

112-
1. Select **Configure** in the **Review** tab to confirm External ID (CIAM) tenant update.
127+
1. Select **Configure** in the **Review** tab to confirm external tenant update.
113128

114-
1. The browser opens **Add an identity provider**.
129+
1. The browser returns to the **Add an identity provider** page.
115130

116-
1. In the **App Service authentication settings** section, select:
131+
1. In the **Additional checks** section, select:
117132

118133
- **Allow requests only from this application itself** for **Client application requirement**
119134
- **Allow requests from any identity** for **Identity requirement**
@@ -131,9 +146,9 @@ Now that you have a web app running on App Service, enable authentication and au
131146

132147
## 4. Verify limited access to the web app
133148

134-
When you enabled the App Service authentication/authorization module in the previous section, an app registration was created in your workforce or customer (external) tenant. The app registration has the same display name as your web app.
149+
When you enabled the App Service authentication/authorization module in the previous section, an app registration was created in your workforce or external tenant. The app registration has the display name you created in a previous step.
135150

136-
1. To check the settings, sign in to the [Microsoft Entra admin center](https://entra.microsoft.com) as at least an [Application Developer](/entra/identity/role-based-access-control/permissions-reference#application-developer). If necessary, use the **Settings** icon in the top menu to switch to the customer (external) tenant with your web app from the **Directories** + **subscriptions** menu. When you are in the correct tenant:
151+
1. To check the settings, sign in to the [Microsoft Entra admin center](https://entra.microsoft.com) as at least an [Application Developer](/entra/identity/role-based-access-control/permissions-reference#application-developer). If you chose external configuration, use the **Settings** icon in the top menu to switch to the external tenant with your web app from the **Directories** + **subscriptions** menu. When you are in the correct tenant:
137152

138153
1. Browse to **Identity** > **Applications** > **App registrations** and select **Applications** > **App registrations** from the menu.
139154
1. Select the app registration that was created.
Loading
Loading
101 KB
Loading

articles/app-service/overview-authentication-authorization.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ App Service uses [federated identity](https://en.wikipedia.org/wiki/Federated_id
3131

3232
| Provider | Sign-in endpoint | How-To guidance |
3333
| - | - | - |
34-
| [Microsoft identity platform](../active-directory/fundamentals/active-directory-whatis.md) | `/.auth/login/aad` | [App Service Microsoft identity platform login](configure-authentication-provider-aad.md) |
34+
| [Microsoft Entra](/entra/index) | `/.auth/login/aad` | [App Service Microsoft Entra platform login](configure-authentication-provider-aad.md) |
3535
| [Facebook](https://developers.facebook.com/docs/facebook-login) | `/.auth/login/facebook` | [App Service Facebook login](configure-authentication-provider-facebook.md) |
3636
| [Google](https://developers.google.com/identity/choose-auth) | `/.auth/login/google` | [App Service Google login](configure-authentication-provider-google.md) |
3737
| [Twitter](https://developer.twitter.com/en/docs/basics/authentication) | `/.auth/login/twitter` | [App Service Twitter login](configure-authentication-provider-twitter.md) |

0 commit comments

Comments
 (0)