From 6875b4be02529093abf57eb78639b7ae6acc3e40 Mon Sep 17 00:00:00 2001 From: Scott Addie Date: Fri, 11 Sep 2020 10:13:40 -0500 Subject: [PATCH 1/3] Document AAD and AAD B2C authentication breaking change --- docs/core/compatibility/3.1-5.0.md | 5 ++ docs/core/compatibility/aspnetcore.md | 5 ++ .../authentication-aad-packages-obsolete.md | 51 +++++++++++++++++++ 3 files changed, 61 insertions(+) create mode 100644 includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md diff --git a/docs/core/compatibility/3.1-5.0.md b/docs/core/compatibility/3.1-5.0.md index 02bcc6e22498a..bc2db97b3eff5 100644 --- a/docs/core/compatibility/3.1-5.0.md +++ b/docs/core/compatibility/3.1-5.0.md @@ -9,6 +9,7 @@ If you're migrating from version 3.1 of .NET Core, ASP.NET Core, or EF Core to v ## ASP.NET Core +- [Authentication: AzureAD.UI and AzureADB2C.UI APIs and packages marked obsolete](#authentication-azureadui-and-azureadb2cui-apis-and-packages-marked-obsolete) - [Authorization: Resource in endpoint routing is HttpContext](#authorization-resource-in-endpoint-routing-is-httpcontext) - [Azure: Microsoft-prefixed Azure integration packages removed](#azure-microsoft-prefixed-azure-integration-packages-removed) - [Blazor: Insignificant whitespace trimmed from components at compile time](#blazor-insignificant-whitespace-trimmed-from-components-at-compile-time) @@ -35,6 +36,10 @@ If you're migrating from version 3.1 of .NET Core, ASP.NET Core, or EF Core to v - [SignalR: UseSignalR and UseConnections methods removed](#signalr-usesignalr-and-useconnections-methods-removed) - [Static files: CSV content type changed to standards-compliant](#static-files-csv-content-type-changed-to-standards-compliant) +[!INCLUDE[Authentication: AzureAD.UI and AzureADB2C.UI APIs and packages marked obsolete](~/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md)] + +*** + [!INCLUDE[Authorization: Resource in endpoint routing is HttpContext](~/includes/core-changes/aspnetcore/5.0/authorization-resource-in-endpoint-routing.md)] *** diff --git a/docs/core/compatibility/aspnetcore.md b/docs/core/compatibility/aspnetcore.md index 919503fbd1b8e..50b604fb4e4ff 100644 --- a/docs/core/compatibility/aspnetcore.md +++ b/docs/core/compatibility/aspnetcore.md @@ -19,6 +19,7 @@ Select one of the following links for breaking changes in a specific version: The following breaking changes in ASP.NET Core 3.0, 3.1, and 5.0 are documented on this page: - [Obsolete Antiforgery, CORS, Diagnostics, MVC, and Routing APIs removed](#obsolete-antiforgery-cors-diagnostics-mvc-and-routing-apis-removed) +- [Authentication: AzureAD.UI and AzureADB2C.UI APIs and packages marked obsolete](#authentication-azureadui-and-azureadb2cui-apis-and-packages-marked-obsolete) - [Authentication: Google+ deprecation](#authentication-google-deprecated-and-replaced) - [Authentication: HttpContext.Authentication property removed](#authentication-httpcontextauthentication-property-removed) - [Authentication: Newtonsoft.Json types replaced](#authentication-newtonsoftjson-types-replaced) @@ -99,6 +100,10 @@ The following breaking changes in ASP.NET Core 3.0, 3.1, and 5.0 are documented ## ASP.NET Core 5.0 +[!INCLUDE[Authentication: AzureAD.UI and AzureADB2C.UI APIs and packages marked obsolete](~/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md)] + +*** + [!INCLUDE[Authorization: Resource in endpoint routing is HttpContext](~/includes/core-changes/aspnetcore/5.0/authorization-resource-in-endpoint-routing.md)] *** diff --git a/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md b/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md new file mode 100644 index 0000000000000..9873e18fff652 --- /dev/null +++ b/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md @@ -0,0 +1,51 @@ +### Authentication: AzureAD.UI and AzureADB2C.UI APIs and packages marked obsolete + +In ASP.NET Core 2.1, integration with Azure Active Directory (Azure AD) and Azure Active Directory B2C (Azure AD B2C) authentication is provided by the [Microsoft.AspNetCore.Authentication.AzureAD.UI](https://www.nuget.org/packages/Microsoft.AspNetCore.Authentication.AzureAD.UI) and [Microsoft.AspNetCore.Authentication.AzureADB2C.UI](https://www.nuget.org/packages/Microsoft.AspNetCore.Authentication.AzureADB2C.UI) packages. The functionality provided by these packages is based on the Azure AD v1.0 endpoint. + +In ASP.NET Core 5.0 and later, integration with Azure AD and Azure AD B2C authentication is provided by the [Microsoft.Identity.Web](https://www.nuget.org/packages/Microsoft.Identity.Web) package. This package is based on the Microsoft Identity Platform, which is formerly known as the Azure AD v2.0 endpoint. Consequently, the old APIs in the `Microsoft.AspNetCore.Authentication.AzureAD.UI` and `Microsoft.AspNetCore.Authentication.AzureADB2C.UI` packages were deprecated. + +#### Version introduced + +5.0 Preview 8 + +#### Old behavior + +The APIs weren't marked as obsolete. + +#### New behavior + +The APIs are marked as obsolete. + +#### Reason for change + +The Azure AD and Azure AD B2C authentication functionality was migrated to Microsoft Authentication Library (MSAL) APIs that are provided by `Microsoft.Identity.Web`. + +#### Recommended action + +Follow the `Microsoft.Identity.Web` API documentation for [web apps](https://github.com/azuread/microsoft-identity-web/wiki/web-apps) and [web APIs](https://github.com/azuread/microsoft-identity-web/wiki/web-apis). + +#### Category + +ASP.NET Core + +#### Affected APIs + +* [Microsoft.AspNetCore.Authentication.AzureADAuthenticationBuilderExtensions](/dotnet/api/microsoft.aspnetcore.authentication.azureadauthenticationbuilderextensions?view=aspnetcore-3.0) +* [Microsoft.AspNetCore.Authentication.AzureAD.UI.AzureADDefaults](/dotnet/api/microsoft.aspnetcore.authentication.azuread.ui.azureaddefaults?view=aspnetcore-3.0) +* [Microsoft.AspNetCore.Authentication.AzureAD.UI.AzureADOptions](/dotnet/api/microsoft.aspnetcore.authentication.azuread.ui.azureadoptions?view=aspnetcore-3.0) +* [Microsoft.AspNetCore.Authentication.AzureADB2CAuthenticationBuilderExtensions](/dotnet/api/microsoft.aspnetcore.authentication.azureadb2cauthenticationbuilderextensions?view=aspnetcore-3.0) +* [Microsoft.AspNetCore.Authentication.AzureADB2C.UI.AzureADB2CDefaults](/dotnet/api/microsoft.aspnetcore.authentication.azureadb2c.ui.azureadb2cdefaults?view=aspnetcore-3.0) +* [Microsoft.AspNetCore.Authentication.AzureADB2C.UI.AzureADB2COptions](/dotnet/api/microsoft.aspnetcore.authentication.azureadb2c.ui.azureadb2coptions?view=aspnetcore-3.0) + + From d2aaf3bfb303af7f4f8b0d1ce6dc261c970c3ad7 Mon Sep 17 00:00:00 2001 From: Scott Addie Date: Fri, 11 Sep 2020 10:16:43 -0500 Subject: [PATCH 2/3] Add link to GitHub discussion issue --- .../aspnetcore/5.0/authentication-aad-packages-obsolete.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md b/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md index 9873e18fff652..e5072b35ce78d 100644 --- a/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md +++ b/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md @@ -4,6 +4,8 @@ In ASP.NET Core 2.1, integration with Azure Active Directory (Azure AD) and Azur In ASP.NET Core 5.0 and later, integration with Azure AD and Azure AD B2C authentication is provided by the [Microsoft.Identity.Web](https://www.nuget.org/packages/Microsoft.Identity.Web) package. This package is based on the Microsoft Identity Platform, which is formerly known as the Azure AD v2.0 endpoint. Consequently, the old APIs in the `Microsoft.AspNetCore.Authentication.AzureAD.UI` and `Microsoft.AspNetCore.Authentication.AzureADB2C.UI` packages were deprecated. +For discussion, see GitHub issue [dotnet/aspnetcore#25807](https://github.com/dotnet/aspnetcore/issues/25807). + #### Version introduced 5.0 Preview 8 From 8f59b35fc86f2d3873d2586037c068fbda9859f5 Mon Sep 17 00:00:00 2001 From: Scott Addie Date: Mon, 14 Sep 2020 15:15:03 -0500 Subject: [PATCH 3/3] React to feedback --- .../aspnetcore/5.0/authentication-aad-packages-obsolete.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md b/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md index e5072b35ce78d..db5488192f533 100644 --- a/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md +++ b/includes/core-changes/aspnetcore/5.0/authentication-aad-packages-obsolete.md @@ -24,7 +24,7 @@ The Azure AD and Azure AD B2C authentication functionality was migrated to Micro #### Recommended action -Follow the `Microsoft.Identity.Web` API documentation for [web apps](https://github.com/azuread/microsoft-identity-web/wiki/web-apps) and [web APIs](https://github.com/azuread/microsoft-identity-web/wiki/web-apis). +Follow the `Microsoft.Identity.Web` API guidance for [web apps](https://github.com/azuread/microsoft-identity-web/wiki/web-apps) and [web APIs](https://github.com/azuread/microsoft-identity-web/wiki/web-apis). #### Category