aspnet / Identity

[Archived] ASP.NET Core Identity is the membership system for building ASP.NET Core web applications, including membership, login, and user data. Project moved to https://github.com/aspnet/AspNetCore
Apache License 2.0
1.96k stars 869 forks source link

Does asp net core identity supports the hierarchy based resource access? #1943

Closed saurabhlogward closed 6 years ago

saurabhlogward commented 6 years ago

I am planning To use the asp net identity as a web api for my use case where I have to create a company based hierarchy and based on which I need to provide the resource access. I can have many such hierarchy for each company accounts. All I need to achieve through asp net core identity is, identifying the logged in user, to which company it belongs to and what can he/she have access to with in the hierarchy.

Is this achievable using asp net core identity?

brockallen commented 6 years ago

Identity != Permissions

saurabhlogward commented 6 years ago

@brockallen I think the asp net core identity also provides the Authorization mechanism so I believe it should do that. Isn’t it ?

brockallen commented 6 years ago

ASP.NET Core does, yes. But that's different than ASP.NET Core Identity.

blowdart commented 6 years ago

Identity doesn't provide authorization, Identity is basically a user database. How you make use of the identities it populates is a separate concern.

(But yes, it would be possible, depending on how you extend the identity model and then plug it into resource authorization)