AbstractContentSecurityPolicyReporter implements MiddlewareInterface
AbstractYes
Table of Contents
Interfaces
- MiddlewareInterface
Constants
- URI_KEYS = ['document-uri', 'report-uri', 'blocked-uri', 'referrer']
Properties
Methods
- __construct() : mixed
- anonymizeDetails() : array<string|int, mixed>
- anonymizeUri() : string
- generateReportSummary() : string
- isCspReport() : bool
- isJson() : bool
- persistCspReport() : void
Constants
URI_KEYS
protected
mixed
URI_KEYS
= ['document-uri', 'report-uri', 'blocked-uri', 'referrer']
Properties
$hashService read-only
protected
HashService
$hashService
$policyProvider read-only
protected
PolicyProvider
$policyProvider
$reportRepository read-only
protected
ReportRepository
$reportRepository
Methods
__construct()
public
__construct(PolicyProvider $policyProvider, ReportRepository $reportRepository, HashService $hashService) : mixed
Parameters
- $policyProvider : PolicyProvider
- $reportRepository : ReportRepository
- $hashService : HashService
anonymizeDetails()
protected
anonymizeDetails(array<string|int, mixed> $details) : array<string|int, mixed>
Parameters
- $details : array<string|int, mixed>
Return values
array<string|int, mixed>anonymizeUri()
protected
anonymizeUri(string $value) : string
Parameters
- $value : string
Return values
stringgenerateReportSummary()
protected
generateReportSummary(Scope $scope, ReportDetails $details) : string
Parameters
- $scope : Scope
- $details : ReportDetails
Return values
stringisCspReport()
protected
isCspReport(Scope $scope, ServerRequestInterface $request) : bool
Parameters
- $scope : Scope
- $request : ServerRequestInterface
Return values
boolisJson()
protected
isJson(string $value) : bool
Parameters
- $value : string
Return values
boolpersistCspReport()
protected
persistCspReport(Scope $scope, ServerRequestInterface $request) : void
Parameters
- $scope : Scope
- $request : ServerRequestInterface