November Happy Hour will be moved to Thursday December 5th.

Class PrincipalInfo

Legacy helper that wraps IPrincipalAccessor

Inheritance
System.Object
PrincipalInfo
Namespace: EPiServer.Security
Assembly: EPiServer.Cms.AspNetCore.dll
Version: 12.0.3
Syntax
public class PrincipalInfo : Object

Constructors

PrincipalInfo(IPrincipal)

Obsolete method, use IPrincipal directly

Declaration
public PrincipalInfo(IPrincipal principal)
Parameters
Type Name Description
System.Security.Principal.IPrincipal principal

Properties

CurrentPrincipal

Declaration
public static IPrincipal CurrentPrincipal { get; }
Property Value
Type Description
System.Security.Principal.IPrincipal

HasEditAccess

Checks for user is in the role CmsEditors or if the current request is in edit mode

Declaration
public static bool HasEditAccess { get; }
Property Value
Type Description
System.Boolean

Methods

IsPermitted(PermissionType)

Obsolete method, use PermissionService.IsPermitted

Declaration
public bool IsPermitted(PermissionType permissionType)
Parameters
Type Name Description
PermissionType permissionType
Returns
Type Description
System.Boolean

Extension Methods