Cyber Risks · PortSwigger Research

Content security policy: not enforced

Summary: PortSwigger Research describes Content Security Policy as a mechanism that mitigates cross-site scripting by disabling dangerous behaviors such as untrusted JavaScript execution, specified through a response header or meta tag. The finding is that a site is using the Content-Security-Policy-Report-Only header rather than the enforcing Content-Security-Policy header, and PortSwigger recommends transitioning to the enforcing header for effective policy enforcement.

Bottom line: A report-only CSP records violations but blocks nothing, so the cross-site scripting protection the policy was written for is not actually in force until the header is switched to enforcing.

Read the original at PortSwigger Research ↗

Topics
Vulnerabilities & Patching
Related