Hi Demis,
we are using the RoleNames.Admin
for a “root” user which passes all auth checks. While it is working in the RequiredRoleAttribute
, it doesn’t with RequiresAnyRole
.
In the RequiredRoleAttribute
i can find:
if (session != null && session.HasRole(RoleNames.Admin))
return;
but there is nothing in the RequiresAnyRoleAttribute.Execute()
method. Is that by design or just forgotten?
At least in my understanding, the RequiresAnyRoleAttribute.Execute()
should return true if the user is in the RoleNames.Admin
.
Regards
Tobi
Edit: Same with RequiresAnyPermissionAttribute.Execute