From: Marius Gavrilescu Date: Wed, 25 Feb 2015 20:23:27 +0000 (+0200) Subject: Update Content-Security-Policy to version 2 X-Git-Url: http://git.ieval.ro/?a=commitdiff_plain;h=031ffaf58cc26884316489ca7d99a867840bf957;p=plack-app-gruntmaster.git Update Content-Security-Policy to version 2 --- diff --git a/app.psgi b/app.psgi index dc9f75b..c61b8bb 100644 --- a/app.psgi +++ b/app.psgi @@ -13,7 +13,21 @@ use Tie::Hash::Expire; use constant AUTH_TIMEOUT => 5 * 60; use constant ACCESSLOG_FORMAT => 'combined'; -use constant CONTENT_SECURITY_POLICY => q,default-src 'none'; script-src 'self'; style-src 'self'; img-src 'self'; connect-src 'self',; + +sub CONTENT_SECURITY_POLICY () { + my $csp = <connect($ENV{GRUNTMASTER_DSN} // 'dbi:Pg:');