MembershipIdentityProvider.SqlServer
2.0.0
dotnet add package MembershipIdentityProvider.SqlServer --version 2.0.0
NuGet\Install-Package MembershipIdentityProvider.SqlServer -Version 2.0.0
<PackageReference Include="MembershipIdentityProvider.SqlServer" Version="2.0.0" />
<PackageVersion Include="MembershipIdentityProvider.SqlServer" Version="2.0.0" />
<PackageReference Include="MembershipIdentityProvider.SqlServer" />
paket add MembershipIdentityProvider.SqlServer --version 2.0.0
#r "nuget: MembershipIdentityProvider.SqlServer, 2.0.0"
#:package MembershipIdentityProvider.SqlServer@2.0.0
#addin nuget:?package=MembershipIdentityProvider.SqlServer&version=2.0.0
#tool nuget:?package=MembershipIdentityProvider.SqlServer&version=2.0.0
#Simple Configuration
Include the following code in the Program.cs
file somewhere before the builder.build() call.
Create an appsettings.json
file in the root of the project and create a DefaultConnection
under ConnectionStrings
and a MembershipSettings entry:
{ "ConnectionStrings": { "DefaultConnection": "YOUR SQL SERVER CONNECTION STRING" }, "MembershipSettings": { "PasswordFormat": 1, "ApplicationId": "F667FF98-9169-4A1E-9A69-1D1E749E0BEA" }, }
In the services add the following line:
builder.Services.AddOptions<MembershipSettings>().BindConfiguration(nameof(MembershipSettings));
Then add the following code to the Program.cs file:
var connectionString = builder.Configuration.GetConnectionString("DefaultConnection") ?? throw new InvalidOperationException("Connection string 'DefaultConnection' not found."); var membershipSettings = new MembershipSettings(); builder.Configuration.GetSection("MembershipSettings").Bind(membershipSettings); builder.Services.AddMembershipIdentitySqlServer<MembershipUser, MembershipRole>(connectionString, membershipSettings);
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. 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. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- Dapper (>= 2.1.35)
- MembershipIdentityProvider (>= 2.0.0)
- Microsoft.Data.SqlClient (>= 5.2.2)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Allows for Login/Logout using the Sql Server provider with provided Roles