PolicyDecisionPointInterface

interface \TYPO3\CMS\Core\Security\Authorization\Policy\PolicyDecisionPointInterface

The policy decision point (PDP) answers one question for the Core voters: does a grant of the principal cover this scope on this resource? It knows where grants are stored, the voters know when a grant is needed at all, for example for a module with the access "admin".

A PDP only knows the resource types and scopes it has grants for, see supports(). For those, decide() answers allow or deny, never abstain. Voters ask supports() first and abstain otherwise, so that a voter of an extension decides on resource types of its own.

Table of Contents

Methods

decide()  : bool
Whether a grant of the principal covers the scope on the resource, false for a scope or resource type the PDP does not support.
supports()  : bool
Whether grants for the scope on the type of the resource exist at all.

Methods

decide()

Whether a grant of the principal covers the scope on the resource, false for a scope or resource type the PDP does not support.

public decide(Principal $principal, string $scope, ResourceIdentifier $resource) : bool

Parameters

$principal : Principal
$scope : string
$resource : ResourceIdentifier

Return values

bool

supports()

Whether grants for the scope on the type of the resource exist at all.

public supports(string $scope, ResourceIdentifier $resource) : bool

Parameters

$scope : string
$resource : ResourceIdentifier

Return values

bool
On this page