‪TYPO3CMS  ‪main
TYPO3\CMS\Core\Security\ContentSecurityPolicy\PolicyProvider Class Reference

Public Member Functions

 __construct (private readonly RequestId $requestId, private readonly SiteFinder $siteFinder, private readonly PolicyRegistry $policyRegistry, private readonly EventDispatcherInterface $eventDispatcher, protected readonly MutationRepository $mutationRepository,)
 
 provideFor (Scope $scope)
 
 getReportingUrlFor (Scope $scope, ServerRequestInterface $request)
 
 getDefaultReportingUriBase (Scope $scope, ServerRequestInterface $request, bool $absolute=true)
 

Protected Attributes

const REPORTING_URI = '@http-reporting'
 

Private Member Functions

 resolveSite (Scope $scope)
 

Detailed Description

Provide a Content-Security-Policy representation for a given scope (e.g. backend, frontend, frontend.my-site).

Definition at line 36 of file PolicyProvider.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Core\Security\ContentSecurityPolicy\PolicyProvider::__construct ( private readonly RequestId  $requestId,
private readonly SiteFinder  $siteFinder,
private readonly PolicyRegistry  $policyRegistry,
private readonly EventDispatcherInterface  $eventDispatcher,
protected readonly MutationRepository  $mutationRepository 
)

Definition at line 40 of file PolicyProvider.php.

Member Function Documentation

◆ getDefaultReportingUriBase()

TYPO3\CMS\Core\Security\ContentSecurityPolicy\PolicyProvider::getDefaultReportingUriBase ( Scope  $scope,
ServerRequestInterface  $request,
bool  $absolute = true 
)

◆ getReportingUrlFor()

TYPO3\CMS\Core\Security\ContentSecurityPolicy\PolicyProvider::getReportingUrlFor ( Scope  $scope,
ServerRequestInterface  $request 
)

◆ provideFor()

TYPO3\CMS\Core\Security\ContentSecurityPolicy\PolicyProvider::provideFor ( Scope  $scope)

Provides the complete, dynamically mutated policy to be used in HTTP responses.

Definition at line 51 of file PolicyProvider.php.

◆ resolveSite()

TYPO3\CMS\Core\Security\ContentSecurityPolicy\PolicyProvider::resolveSite ( Scope  $scope)
private

Member Data Documentation

◆ REPORTING_URI

const TYPO3\CMS\Core\Security\ContentSecurityPolicy\PolicyProvider::REPORTING_URI = '@http-reporting'
protected

Definition at line 38 of file PolicyProvider.php.