Table of Contents

Class PermissionHandler

Namespace
Oqtane.Security
Assembly
Oqtane.Server.dll
public class PermissionHandler : AuthorizationHandler<PermissionRequirement>
Inheritance
object
AuthorizationHandler<PermissionRequirement>
PermissionHandler

Constructors

PermissionHandler(IHttpContextAccessor, IUserPermissions, ILogManager)

public PermissionHandler(IHttpContextAccessor accessor, IUserPermissions userPermissions, ILogManager logger)

Parameters

accessor IHttpContextAccessor
userPermissions IUserPermissions
logger ILogManager

Methods

HandleRequirementAsync(AuthorizationHandlerContext, PermissionRequirement)

Makes a decision if authorization is allowed based on a specific requirement.

protected override Task HandleRequirementAsync(AuthorizationHandlerContext context, PermissionRequirement requirement)

Parameters

context AuthorizationHandlerContext

The authorization context.

requirement PermissionRequirement

The requirement to evaluate.

Returns

Task