Active-directory-dotnet-native-aspnetcore-v2 which shows how to call an ASP.NET Core Web API from a WPF application using Azure AD v2.Note that some of these examples present web apps which also call a web API with MSAL.NET. If you are interested in protecting a Web API with Microsoft Entra ID, you might want to check out: MSAL.NET is about acquiring tokens, not protecting an API Helps you troubleshoot the app by exposing actionable exceptions, logging, and telemetry.Helps you set-up the application through configuration files.Helps you specify which audience you want your application to sign-in (your organization, several organizations, work and school and Microsoft personal accounts, social identities with Azure AD B2C, users in sovereign and national clouds).Eliminates the need for you to handle token expiration by yourself.Maintains a token cache and refreshes tokens for you when they are close to expire.Using MSAL.NET adds value over using OAuth libraries and coding against the protocol by: These web APIs can be the Microsoft Graph API, other Microsoft APIS, 3rd party Web APIs, or your own Web API.Īs a token acquisition library, MSAL.NET provides several ways of getting a token, with a consistent API for a number of platforms. NET applications to acquire tokens in order to call secured web APIs. MSAL.NET ( Microsoft Authentication Library for. Most of the articles in this MSAL.NET reference content describe the most complete platform (.NET Framework), but, topic by topic, it occasionally calls out differences between platforms. On public clients (mobile and desktop), the default browser and redirect URIs are different from platform to platform and broker availability varies (details in browser usage documentation).Mobile platforms (Xamarin, MAUI and UWP) do not allow confidential client flows, because they are not meant to function as a backend and cannot store secrets securely. Not all the authentication features are available in all platforms, mostly because:
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |