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/app-service/configure-authentication-provider-aad.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -63,7 +63,7 @@ During creation of the app registration, collect the following information which
63
63
- Client secret (optional, but recommended)
64
64
- Application ID URI
65
65
66
-
The instructions for creating an app registration depend on if you're using [a workforce tenant](../active-directory/fundamentals/active-directory-whatis.md) or [a customer tenant (Preview)][Azure Active Directory for customers (Preview)]. Use the tabs below to select the right set of instructions for your scenario.
66
+
The instructions for creating an app registration depend on if you're using [a workforce tenant](../active-directory/fundamentals/active-directory-whatis.md) or [a customer tenant][Azure Active Directory for customers (Preview)]. Use the tabs below to select the right set of instructions for your scenario.
67
67
68
68
To register the app, perform the following steps:
69
69
@@ -74,7 +74,7 @@ To register the app, perform the following steps:
74
74
75
75
From the portal menu, select **Microsoft Entra ID**. If the tenant you're using is different from the one you use to configure the App Service application, you'll need to [change directories][Switch your directory] first.
1. If you do not already have a customer tenant, create one by following the instructions in [Create a customer identity and access management (CIAM) tenant](../active-directory/external-identities/customers/how-to-create-customer-tenant-portal.md).
80
80
@@ -117,7 +117,7 @@ To register the app, perform the following steps:
117
117
118
118
No other steps are required for a workforce tenant.
1. Create a user flow, which defines an authentication experience that can be shared across app registrations in the tenant:
123
123
@@ -156,7 +156,7 @@ To register the app, perform the following steps:
156
156
157
157
The **authentication endpoint** for a workforce tenant should be a [value specific to the cloud environment](../active-directory/develop/authentication-national-cloud.md#azure-ad-authentication-endpoints). For example, a workforce tenant in global Azure would use "https://login.microsoftonline.com" as its authentication endpoint. Make note of the authentication endpoint value, as it's needed to construct the right **Issuer URL**.
Copy file name to clipboardExpand all lines: articles/app-service/identity-scenarios.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
@@ -5,7 +5,7 @@ author: rwike77
5
5
manager: CelesteDG
6
6
ms.author: ryanwi
7
7
ms.topic: conceptual
8
-
ms.date: 10/31/2023
8
+
ms.date: 03/14/2024
9
9
ms.custom: AppServiceIdentity
10
10
---
11
11
# Authentication scenarios and recommendations
@@ -15,8 +15,8 @@ If you have a web app or an API running in Azure App Service, you can restrict a
15
15
## Authentication solutions
16
16
17
17
-**Azure App Service built-in authentication** - Allows you to sign users in and access data by writing minimal or no code in your web app, RESTful API, or mobile back end. It’s built directly into the platform and doesn’t require any particular language, library, security expertise, or even any code to use.
18
-
-**Microsoft Authentication Library (MSAL)** - Enables developers to acquire security tokens from the Microsoft identity platform to authenticate users and access secured web APIs. Available for multiple supported platforms and frameworks, these are general purpose libraries that can be used in various hosted environments. Developers can also integrate with multiple sign-in providers, like Microsoft Entra ID, Facebook, Google, Twitter.
19
-
-**Microsoft.Identity.Web** - A higher-level library wrapping MSAL.NET, it provides a set of ASP.NET Core abstractions that simplify adding authentication support to web apps and web APIs integrating with the Microsoft identity platform. It provides a single-surface API convenience layer that ties together ASP.NET Core, its authentication middleware, and MSAL.NET. This library can be used in apps in various hosted environments. You can integrate with multiple sign-in providers, like Microsoft Entra ID, Facebook, Google, Twitter.
18
+
-**Microsoft Authentication Library (MSAL)** - Enables developers to acquire security tokens from the Microsoft identity platform to authenticate users and access secured web APIs. Available for multiple supported platforms and frameworks, these are general purpose libraries that can be used in various hosted environments. Developers can also integrate with multiple sign-in providers, like Microsoft Entra, Facebook, Google, Twitter.
19
+
-**Microsoft.Identity.Web** - A higher-level library wrapping MSAL.NET, it provides a set of ASP.NET Core abstractions that simplify adding authentication support to web apps and web APIs integrating with the Microsoft identity platform. It provides a single-surface API convenience layer that ties together ASP.NET Core, its authentication middleware, and MSAL.NET. This library can be used in apps in various hosted environments. You can integrate with multiple sign-in providers, like Microsoft Entra, Facebook, Google, Twitter.
Copy file name to clipboardExpand all lines: articles/app-service/includes/tutorial-set-up-app-service-authentication/after.md
+72-10Lines changed: 72 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ manager: CelesteDG
7
7
8
8
ms.service: app-service
9
9
ms.topic: include
10
-
ms.date: 02/25/2022
10
+
ms.date: 03/12/2024
11
11
ms.author: ryanwi
12
12
ms.reviewer: stsoneff
13
13
ms.custom: azureday1
@@ -37,29 +37,31 @@ You need these names throughout this tutorial.
37
37
38
38
## 3. Configure authentication and authorization
39
39
40
-
Now that you have a web app running on App Service, enable authentication and authorization. You use Microsoft Entra ID as the identity provider. For more information, see [Configure Microsoft Entra authentication for your App Service application](../../configure-authentication-provider-aad.md).
40
+
Now that you have a web app running on App Service, enable authentication and authorization. You use Microsoft Entra as the identity provider. For more information, see [Configure Microsoft Entra authentication for your App Service application](../../configure-authentication-provider-aad.md).
1. In the [Azure portal](https://portal.azure.com) menu, select **Resource groups**, or search for and select **Resource groups** from any page.
43
45
44
46
1. In **Resource groups**, find and select your resource group. In **Overview**, select your app's management page.
45
47
46
48
:::image type="content" alt-text="Screenshot that shows selecting your app's management page." source="../../media/scenario-secure-app-authentication-app-service/select-app-service.png":::
47
49
48
-
1. On your app's left menu, select **Authentication**, and then click**Add identity provider**.
50
+
1. On your app's left menu, select **Authentication**, and then select**Add identity provider**.
49
51
50
-
1. In the **Add an identity provider** page, for example select **Microsoft** as the **Identity provider** to sign in Microsoft and Microsoft Entra identities.
52
+
1. In the **Add an identity provider** page, select **Microsoft** as the **Identity provider** to sign in Microsoft and Microsoft Entra identities.
51
53
52
-
1.Select a **Tenant type**, for example **Workforce** for work and school accounts or Microsoft accounts.
54
+
1.For **Tenant type**, select **Workforce configuration (current tenant)** for employees and business guests.
53
55
54
-
1. For **App registration** > **App registration type**, select **Create new app registration** to create a new app registration in Microsoft Entra ID.
56
+
1. For **App registration** > **App registration type**, select **Create new app registration** to create a new app registration in Microsoft Entra.
55
57
56
58
1. Add a **Name** for the app registration, a public facing display name.
57
59
58
60
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.
59
61
60
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**.
61
63
62
-
1. At the bottom of the **Add an identity provider** page, click**Add** to enable authentication for your web app.
64
+
1. At the bottom of the **Add an identity provider** page, select**Add** to enable authentication for your web app.
63
65
64
66
:::image type="content" alt-text="Screenshot that shows configuring authentication." source="../../media/scenario-secure-app-authentication-app-service/configure-authentication.png":::
65
67
@@ -69,15 +71,75 @@ Now that you have a web app running on App Service, enable authentication and au
69
71
> To allow accounts from other tenants, change the 'Issuer URL' to 'https://login.microsoftonline.com/common/v2.0' by editing your 'Identity Provider' from the 'Authentication' blade.
1. In the [Azure portal](https://portal.azure.com) menu, select **Resource groups**, or search for and select **Resource groups** from any page.
77
+
78
+
1. In **Resource groups**, find and select your resource group. In **Overview**, select your app's management page.
79
+
80
+
:::image type="content" alt-text="Screenshot that shows selecting your app's management page." source="../../media/scenario-secure-app-authentication-app-service/select-app-service.png":::
81
+
82
+
1. On your app's left menu, select **Authentication**, and then select **Add identity provider**.
83
+
84
+
1. In the **Add an identity provider** page, select **Microsoft** as the **Identity provider** to sign in Microsoft and Microsoft Entra identities.
85
+
86
+
1. For **Tenant type**, select **External configuration** for external users.
87
+
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.
89
+
90
+
1. Select **Configure** to configure external authentication.
91
+
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":::
93
+
94
+
1. The browser opens **Configure customer authentication**. In **Setup sign-in**, select **Create new** to create a sign-in experience for your external users.
95
+
96
+
1. Enter a **Name** for the user flow.
97
+
98
+
1. For this quickstart, select **Email and password** which allows new users to sign up and sign in using an email address as the sign-in name and a password as their first factor credential.
99
+
100
+
1. Select **Create** to create the user flow.
101
+
102
+
:::image type="content" alt-text="Screenshot that shows creating a user flow." source="../../media/scenario-secure-app-authentication-app-service/configure-authentication-external-user-flow.png":::
103
+
104
+
1. Select **Next** to customize branding.
105
+
106
+
1. Add your company logo, select a background color, and select a sign-in layout.
107
+
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":::
109
+
110
+
1. Select **Next** and **Yes, update the changes** to accept the branding changes.
111
+
112
+
1. Select **Configure** in the **Review** tab to confirm External ID (CIAM) tenant update.
113
+
114
+
1. The browser opens **Add an identity provider**.
115
+
116
+
1. In the **App Service authentication settings** section, select:
117
+
118
+
-**Allow requests only from this application itself** for **Client application requirement**
119
+
-**Allow requests from any identity** for **Identity requirement**
120
+
-**Allow requests only from the issuer tenant** for **Tenant requirement**
121
+
122
+
1. In the **App Service authentication settings** section, set:
123
+
-**Require authentication** for **Authentication**
124
+
-**HTTP 302 Found redirect: recommended for websites** for **Unauthenticated requests**
125
+
-**Token store** box
126
+
127
+
1. At the bottom of the **Add an identity provider** page, select **Add** to enable authentication for your web app.
128
+
129
+
:::image type="content" alt-text="Screenshot that shows the Additional checks and authentication settings sections." source="../../media/scenario-secure-app-authentication-app-service/configure-authentication-external-enable.png":::
130
+
---
131
+
72
132
## 4. Verify limited access to the web app
73
133
74
-
When you enabled the App Service authentication/authorization module in the previous section, an app registration was created in your Microsoft Entra tenant. The app registration has the same display name as your web app.
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.
135
+
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:
75
137
76
-
1.To check the settings, go to the [Microsoft Entra admin center](https://entra.microsoft.com)and select **Applications**and then**App registrations** from the menu.
138
+
1.Browse to **Identity** > **Applications** > **App registrations**and select **Applications**>**App registrations** from the menu.
77
139
1. Select the app registration that was created.
78
140
1. In the overview, verify that **Supported account types** is set to **My organization only**.
79
141
80
-
1. To verify that access to your app is limited to users in your organization, got to your web app **Overview** and select the **Default domain** link. Or, start a browser in incognito or private mode and go to `https://<app-name>.azurewebsites.net`.
142
+
1. To verify that access to your app is limited to users in your organization, go to your web app **Overview** and select the **Default domain** link. Or, start a browser in incognito or private mode and go to `https://<app-name>.azurewebsites.net`.
81
143
82
144
:::image type="content" alt-text="Screenshot that shows verifying access." source="../../media/scenario-secure-app-authentication-app-service/verify-access.png":::
Copy file name to clipboardExpand all lines: articles/app-service/includes/tutorial-set-up-app-service-authentication/intro.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
@@ -22,18 +22,18 @@ In this tutorial, you learn how to:
22
22
> [!div class="checklist"]
23
23
>
24
24
> * Configure authentication for the web app.
25
-
> * Limit access to the web app to users in your organization by using Microsoft Entra ID as the identity provider.
25
+
> * Limit access to the web app to users in your organization by using Microsoft Entra as the identity provider.
26
26
27
27
## Automatic authentication provided by App Service
28
28
29
-
App Service provides built-in authentication and authorization support, so you can sign in users with no code in your web app. Using the optional App Service authentication/authorization module simplifies authentication and authorization for your app. When you are ready for custom authentication and authorization, you build on this architecture.
29
+
App Service provides built-in authentication and authorization support, so you can sign in users with no code in your web app. Using the optional App Service authentication/authorization module simplifies authentication and authorization for your app. When you're ready for custom authentication and authorization, you build on this architecture.
30
30
31
31
App service authentication provides:
32
32
33
33
* Easily turn on and configure through the Azure portal and app settings.
34
34
* No SDKs, specific languages, or changes to application code are required.
0 commit comments