Interface IVirtualRoleAuthorizationSession
Components that will check if a principal is part of a virtual role
Namespace: EPiServer.Security
Assembly: EPiServer.Framework.dll
Version: 11.20.7Syntax
public interface IVirtualRoleAuthorizationSession
Remarks
The default implementation is scoped per request or per thread to get session caching it should never be stored in singleton instances
Methods
IsInVirtualRole(IPrincipal, String, SecurityEntityType, Object)
Determines whether the current principal belongs to the specified virtual role.
Declaration
bool IsInVirtualRole(IPrincipal principal, string role, SecurityEntityType type, object context)
Parameters
Type | Name | Description |
---|---|---|
System.Security.Principal.IPrincipal | principal | The principal that will be forwarded to the provider |
System.String | role | The name of the role for which to check membership. |
SecurityEntityType | type | The security type of the role you want to check |
System.Object | context | The context under which the query is being performed |
Returns
Type | Description |
---|---|
System.Boolean | true if the current principal is a member of the specified role; otherwise, false. |