|
| 1 | +### Authentication: AzureAD.UI and AzureADB2C.UI APIs and packages marked obsolete |
| 2 | + |
| 3 | +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. |
| 4 | + |
| 5 | +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. |
| 6 | + |
| 7 | +For discussion, see GitHub issue [dotnet/aspnetcore#25807](https://github.com/dotnet/aspnetcore/issues/25807). |
| 8 | + |
| 9 | +#### Version introduced |
| 10 | + |
| 11 | +5.0 Preview 8 |
| 12 | + |
| 13 | +#### Old behavior |
| 14 | + |
| 15 | +The APIs weren't marked as obsolete. |
| 16 | + |
| 17 | +#### New behavior |
| 18 | + |
| 19 | +The APIs are marked as obsolete. |
| 20 | + |
| 21 | +#### Reason for change |
| 22 | + |
| 23 | +The Azure AD and Azure AD B2C authentication functionality was migrated to Microsoft Authentication Library (MSAL) APIs that are provided by `Microsoft.Identity.Web`. |
| 24 | + |
| 25 | +#### Recommended action |
| 26 | + |
| 27 | +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). |
| 28 | + |
| 29 | +#### Category |
| 30 | + |
| 31 | +ASP.NET Core |
| 32 | + |
| 33 | +#### Affected APIs |
| 34 | + |
| 35 | +* [Microsoft.AspNetCore.Authentication.AzureADAuthenticationBuilderExtensions](/dotnet/api/microsoft.aspnetcore.authentication.azureadauthenticationbuilderextensions?view=aspnetcore-3.0) |
| 36 | +* [Microsoft.AspNetCore.Authentication.AzureAD.UI.AzureADDefaults](/dotnet/api/microsoft.aspnetcore.authentication.azuread.ui.azureaddefaults?view=aspnetcore-3.0) |
| 37 | +* [Microsoft.AspNetCore.Authentication.AzureAD.UI.AzureADOptions](/dotnet/api/microsoft.aspnetcore.authentication.azuread.ui.azureadoptions?view=aspnetcore-3.0) |
| 38 | +* [Microsoft.AspNetCore.Authentication.AzureADB2CAuthenticationBuilderExtensions](/dotnet/api/microsoft.aspnetcore.authentication.azureadb2cauthenticationbuilderextensions?view=aspnetcore-3.0) |
| 39 | +* [Microsoft.AspNetCore.Authentication.AzureADB2C.UI.AzureADB2CDefaults](/dotnet/api/microsoft.aspnetcore.authentication.azureadb2c.ui.azureadb2cdefaults?view=aspnetcore-3.0) |
| 40 | +* [Microsoft.AspNetCore.Authentication.AzureADB2C.UI.AzureADB2COptions](/dotnet/api/microsoft.aspnetcore.authentication.azureadb2c.ui.azureadb2coptions?view=aspnetcore-3.0) |
| 41 | + |
| 42 | +<!-- |
| 43 | +
|
| 44 | +#### Affected APIs |
| 45 | +
|
| 46 | +- `T:Microsoft.AspNetCore.Authentication.AzureADAuthenticationBuilderExtensions` |
| 47 | +- `T:Microsoft.AspNetCore.Authentication.AzureAD.UI.AzureADDefaults` |
| 48 | +- `T:Microsoft.AspNetCore.Authentication.AzureAD.UI.AzureADOptions` |
| 49 | +- `T:Microsoft.AspNetCore.Authentication.AzureADB2CAuthenticationBuilderExtensions` |
| 50 | +- `T:Microsoft.AspNetCore.Authentication.AzureADB2C.UI.AzureADB2CDefaults` |
| 51 | +- `T:Microsoft.AspNetCore.Authentication.AzureADB2C.UI.AzureADB2COptions` |
| 52 | +
|
| 53 | +--> |
0 commit comments