Skip to content

Provide an endpoint for logging CSP violations #1058

Closed
@php-coder

Description

@php-coder

In order to be notified about Content Security Policy violations, we need to have an endpoint which just prints the report to the log.

Here is an example of such a report (but it's just for information): https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP#Sample_violation_report

Requirements:

  • add new controller (CspController) in ru.mystamps.web.feature.site package
  • add the endpoint that accepts POST requests on /site/csp/reports and outputs the request body to log

Part of #226

Metadata

Metadata

Assignees

Labels

kind/taskTask that is part of some feature

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions