linq2db - IdentityServer4.Contrib.Linq2db 1.0.3-rc26

Linq To DB persistence layer for IdentityServer4

PM> Install-Package IdentityServer4.Contrib.Linq2db -Version 1.0.3-rc26 -Source https://www.myget.org/F/linq2db/api/v3/index.json

Copy to clipboard

> nuget.exe install IdentityServer4.Contrib.Linq2db -Version 1.0.3-rc26 -Source https://www.myget.org/F/linq2db/api/v3/index.json

Copy to clipboard

> dotnet add package IdentityServer4.Contrib.Linq2db --version 1.0.3-rc26 --source https://www.myget.org/F/linq2db/api/v3/index.json

Copy to clipboard
<PackageReference Include="IdentityServer4.Contrib.Linq2db" Version="1.0.3-rc26" />
Copy to clipboard
source https://www.myget.org/F/linq2db/api/v3/index.json

nuget IdentityServer4.Contrib.Linq2db  ~> 1.0.3-rc26
Copy to clipboard

> choco install IdentityServer4.Contrib.Linq2db --version 1.0.3-rc26 --source https://www.myget.org/F/linq2db/api/v2

Copy to clipboard
Import-Module PowerShellGet
Register-PSRepository -Name "linq2db" -SourceLocation "https://www.myget.org/F/linq2db/api/v2"
Install-Module -Name "IdentityServer4.Contrib.Linq2db" -RequiredVersion "1.0.3-rc26" -Repository "linq2db" -AllowPreRelease
Copy to clipboard

IdentityServer4.LinqToDB

  • Current build status Build status
  • Master build status Master status

Intro

IdentityServer4.LinqToDB is a persistence layer for IdentityServer4 configuration data that uses Linq To DB as it's database abstraction.

Project's source code is originally based on IdentityServer4.EntityFramework

Feeds

  • Release builds can be found on NuGet
  • MyGet
    • V2 https://www.myget.org/F/linq2db/api/v2
    • V3 https://www.myget.org/F/linq2db/api/v3/index.json

Usage

Install package:

PM> Install-Package IdentityServer4.Contrib.Linq2db

POCOs

All POCOs are under IdentityServer4.Contrib.LinqToDB.Entities namespace. Mostly POCOs are inherited from IdentityServer4.Models.* classes (to avoid unnesesary mapping), with adding only Id properties for identities and foreign keys. IdentityServer4.Models.Client.ClientId is used as promary key for Client entity. All Id's are identity by default.

Running

Firstly you should create your connection factory as implementation of IdentityServer4.LinqToDB.Interfaces.IDataConnectionFactory, for example:

public class MyConnectionFactory : IDataConnectionFactory
{
    public DataContext GetContext() => new DataContext();
    public DataConnection GetConnection() => new DataConnection();
}

In your Strartup.cs

public IServiceProvider ConfigureServices(IServiceCollection services)
{
    // ...
     
    // create factory instance 
    var factory = new MyConnectionFactory();

    services.AddIdentityServer() // Add IdentityServer
        .AddTemporarySigningCredential()
        // some other stuff

        // Configure Linq To DB storage for IdentityServer
        .AddConfigurationStore(factory)
        .AddOperationalStore(factory);

    // ...
      
    return services.BuildServiceProvider(true);
}
  • .NETFramework 4.5.2
    • IdentityServer4 (>= 1.5.2)
    • linq2db.core (>= 1.10.0)
  • .NETStandard 1.6
    • IdentityServer4 (>= 1.5.2)
    • linq2db.core (>= 1.10.0)
    • NETStandard.Library (>= 1.6.1)
  • .NETFramework 4.5.2: 4.5.2.0
  • .NETStandard 1.6: 1.6.0.0

Owners

Ilya Chudin

Authors

Ilya Chudin

Project URL

https://github.com/linq2db/IdentityServer4.LinqToDB

License

MIT

Tags

OAuth2 OAuth 2.0 OpenID Connect Security Identity IdentityServer linq2db LinqToDB

Info

1 total downloads
1 downloads for version 1.0.3-rc26
Download (40.61 KB)
Found on the current feed only

Package history

Version Size Last updated Downloads Mirrored?
1.0.3-rc26 40.61 KB Sun, 19 Nov 2017 16:42:39 GMT 1