block iframe embedding

protects against clickjacking attacks. I'm not sure if we have any data worth jacking (maybe the youtube form?) but we may in the future.
This commit is contained in:
Alex Grin 2020-09-04 13:04:00 -04:00 committed by GitHub
parent 9e1eb20e96
commit 443543dba9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -249,10 +249,10 @@ class Response
public static function setDefaultSecurityHeaders() public static function setDefaultSecurityHeaders()
{ {
$defaultHeaders = [ $defaultHeaders = [
//'Content-Security-Policy' => "frame-ancestors 'none'", 'Content-Security-Policy' => "frame-ancestors 'none'",
//'X-Frame-Options' => 'DENY', 'X-Frame-Options' => 'DENY',
'X-XSS-Protection' => '1', 'X-XSS-Protection' => '1',
]; ];
if (IS_PRODUCTION) { if (IS_PRODUCTION) {
$defaultHeaders['Strict-Transport-Security'] = 'max-age=31536000'; $defaultHeaders['Strict-Transport-Security'] = 'max-age=31536000';