Identity Server Difference between IdentityServer4.EntityFramework and IdentityServer4.AspNetIdentity

1k views Asked by At

I am new to the Identity Server so please bear with me. Trying to understand following two libs in Identity Server 4.

IdentityServer4.EntityFramework IdentityServer4.AspNetIdentity

I understand that helps out with EF and AspNet. Looking at the source code and the Entities, they both have quite different entities. AspNetIdentity has entities related to the User, Roles etc while EntityFramework things like Client, Resources etc. But both have UserClaim which confuses me a little bit. Is it possible to use both the libraries in a project? or should only use on or other?

If we can use both then what we can do about The UserClaim Entity which are in both library ?

Thanks,

1

There are 1 answers

3
leastprivilege On BEST ANSWER

ASP.NET Identity is an option for user storage, password validation, 2FA etc. (it can be based on EF - but that is not the point)

The EF library is for persisting configuration data (like clients and resources) as well as runtime state (codes, refresh tokens etc) to a EF support database.

And yes - they can be used together.