logo

The npoco idenity provider is a custom AspNet Identity 2.0 Storage Provider that can be used to replace the default Entity Framework identity provider.

nPoco Idenity Provider

The nPoco Identity Provider allows you to replace the out of the box Entity Framework Identity 2.0 Storage Provider with one powered by nPoco.

NPoco.Identity.Provider is an AspNet Identity 2.0 Storage Provider built using NPoco, to use it in your projects you will need to implement the following interfaces where T is the primary key data type:

  • IIdentityUser<T>
  • IIdentityRoles<T>
  • IIdentityClaim<T>
  • IIdentityLogin<T>
  • IIdentityRole<T>

You can use NPoco attributes to provide an alias for your table names and primary key columns. If you are not using strings as your primary key data type then you will need to follow this guide from microsoft. Alternatively you can use the NPoco.Identity.Provider.Website template

To run the tests please create a MSSQL database and run the Database Setup script included in the Database folder. Once the database has been setup you will need to set the connection string in the DatabaseFixture.cs class.