I'm using "IdentityManager.AspNetIdentity" to implement role and claims for an ASP.Net MVC 5.0 Application.
( IdentityManager.AspNetIdentity)
I notice that if create a new role in IdentityManager and I assign it to a specific user, IdentityManager create the role and create a new claim with ClaimType equal to "role".
Picture: Claim Situation
Now... Correct me if I'm wrong:
From MVC Application side, I know that by default, the framework tests the **ClaimType = "
http: //schemas.microsoft.com/ws/2008/06/identity/claims/role
"** in order to implement security when checking security.
Picture: Workaround
Now my solution in order to make IdentityManager and the MVC Application working with same role is to add claims with the ClaimType equal to the Microsoft Schema.
But how can I let the IdentityManager fill the ClaimType with the Microsoft Schema instead of "role" each time I assign a role to a user?
Or on the other side, How can I make Microsoft.Identity2.0 to test "role" ClaimType instead of the schema when testing the role of the user?
Thanks to support