Details on Configuring Use of ASP.NET Identity (OWIN) in the Entity Framework

This blog:

http://blogs.msdn.com/b/webdev/archive/2013/06/27/introducing-asp-net-identity-membership-system-for-asp-net-applications.aspx

ASP.NET Identity Provider says:

Safety control

By default, ASP.NET authentication will store all user information in the database. The ASP.NET identifier uses the Entity Framework Code First to implement its entire persistence mechanism.

If your application requirements are that this information can be stored in another repository such as SharePoint, Azure Table database, No Sql databases, etc., you can now connect different storage providers.

But how can I use the Azure table service with this? My research shows that you cannot use the entity infrastructure using a table service, so I think you will have to completely replace the code that makes full use of the entity structure, but I'm not sure.

Related question: I am new to EF in general. How can we set up a way to store data (even on a SQL server)? I found two examples that show adding additional fields to the user table:

http://www.asp.net/mvc/tutorials/mvc-5/create-an-aspnet-mvc-5-app-with-facebook-and-google-oauth2-and-openid-sign-on

http://www.asp.net/web-api/overview/security/external-authentication-services

But I donโ€™t understand what exactly is happening. I think it uses Entity Framework code first, but I see very little documentation on how to configure how the data is stored by EF for this. For example, is it possible to rename objects? Can I determine what the database will be called?

Thanks...

-Ben

+6
source share
3 answers
  • Asp.Net Identity has a default repository implementation using EntityFramework.

  • Microsoft.AspNet.Identity.Core has a list of interfaces that you need to implement to store data, where and how you want. These interfaces provide the minimum necessary elements and methods.

  • IdentityManager is the main entry point where you can pass the repository user interface implementation.

IdentityManager (Microsoft.AspNet.Identity.IIdentityStore)

Check out this setting for the framework (not related to vault / vault, it will guide you further)

Deploying User Confirmation and Reset Password with a Single ASP.NET Identifier

+3
source

I answered a similar question here with an implementation of a sample azure storage table that should be used against 1.0.0 bit RTM

Azure Table Storage Store

+1
source

This should provide most, if not all, of the details the OP asks for: How to use the Azure table store as an OAuth credential store with web API 2

It seems that C. Scott Allen has begun a series of blog posts headed in these general areas (MongoDB vs. Azure Tables).

+1
source

Source: https://habr.com/ru/post/955250/


All Articles