Data access in DAL with ASP.Net MVC Identity and Owin

2

Today my solution has an MVC 5 Web application project and a Data Access Layer (DAL) Library with EF DatabaseFirst.

I want to create a layer with MVC Identity + Owin, however, I would like data access to be made in the DAL.

How do I do this? Is there a good example that tells you how to separate MVC Identity and Owin data access?

    
asked by anonymous 25.09.2014 / 18:16

1 answer

1

First, ASP.NET Identity and OWIN are not "separable". OWIN is an interface standard , and ASP.NET Identity is an implementation that handles users in your application. ASP.NET Identity may or may not follow OWIN, because it works with it, but it can use another pattern as well, no problem.

Second, to redeploy ASP.NET Identity behavior, you will have to reimplement the following classes:

Once this is done, your system will be able to work with ASP.NET Identity at the DAL level.

The problem is that putting an extra layer on you will be creating a complicator, since the application is implemented using an agnostic data access model with dynamic linking to libraries such as the Entity Framework.

    
25.09.2014 / 20:33