Blazorade.Msal
2.2.0
This package has been deprecated, mainly because of its problems when used with .NET MAUI Blazor Hybrid apps. Another Blazorade library focusing on authentication will come out in the future that will support Blazor on any platform, including .NET MAUI Blazor Hybrid apps.
dotnet add package Blazorade.Msal --version 2.2.0
NuGet\Install-Package Blazorade.Msal -Version 2.2.0
<PackageReference Include="Blazorade.Msal" Version="2.2.0" />
paket add Blazorade.Msal --version 2.2.0
#r "nuget: Blazorade.Msal, 2.2.0"
// Install Blazorade.Msal as a Cake Addin #addin nuget:?package=Blazorade.Msal&version=2.2.0 // Install Blazorade.Msal as a Cake Tool #tool nuget:?package=Blazorade.Msal&version=2.2.0
Blazorade MSAL
Provides easy to use authentication and token acquisition for Blazor applications with the help of Microsoft Authentication Library. Supports both Blazor Server and Blazor WebAssembly applications.
Getting Started
After you have installed the package to your application, refer to the Getting Started section on the package wiki for information on how to easily get started with Blazorade MSAL.
Highlights
Blazorade MSAL facilitates authentication and authorization for instance with the following services.
BlazoradeMsalService
- A service class that handles all communication with the MSAL JavaScript library for you. You don't have to write a single line of JavaScript code in your application.BlazoradeRequestFactory
- A factory service that createsHttpRequestMessage
instances. These request messages are configured with an access token provided byBlazoradeMsalService
which enables you to easily call into APIs such as Microsoft Graph.
These services are registered in your application's service collection with the AddBlazoradeMsal
method as described in the Getting Started section on the Blazoarde MSAL wiki.
Sample Applications
The Github repository for Blazorade MSAL contains several sample applications that demonstrate how you can leverage Blazorade MSAL in your own application.
- GraphClient - A WebAssembly application that demonstrates how to send HTTP requests to Microsoft Graph with the help of Blazorade MSAL. Can be applied to any other REST API that requires access tokens.
- BlazorServerSample - A Blazor Server application that demonstrates how you can make use of the on-demand token acquisition provided by Blazorade MSAL.
- BlazorWasmSample - The same as BlazorServerSample but implemented as a Blazor WebAssembly application. Shares much of the features with the Server sample through the SharedComponentsSample component library.
Version Highlights
This section lists the main improvements in each published version.
v2.2.0
Added support for Azure AD B2C as Identity Provider.
- Azure AD B2C Support
- Getting Started: Added documentation to the Getting Started section on how to configure your application for Azure AD B2C.
v2.1.0
This version includes the following pull requests.
Further Reading
To learn more, read these Blazorade MSAL articles on Mika Berglund's blog.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net6.0
- Blazorade.Core (>= 3.0.0)
- Microsoft.AspNetCore.Components.Web (>= 6.0.2)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.