Interface IAuthorizer<T>

Authorizer to perform role based checks for a principal.

Param

Principal data type, the type must extend Principal

Type Parameters

Hierarchy

  • IAuthorizer

Properties

Methods

Properties

name: string

A human readable name for this authorizer.

Methods

  • Check that a principal has a named role.

    Parameters

    • principal: T

      The current principal context.

    • role: string

      The name of the role to check for.

    Returns Promise<boolean>

    true if the principal is authorised to use the name role, otherwise false.

Generated using TypeDoc