You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ro...@apache.org on 2015/09/03 19:19:01 UTC

fauxton commit: updated refs/heads/master to 1c8d86e

Repository: couchdb-fauxton
Updated Branches:
  refs/heads/master b5affe12a -> 1c8d86e75


allow custom csp header

PR: #514
PR-URL: https://github.com/apache/couchdb-fauxton/pull/514
Reviewed-By: Benjamin Keen <be...@gmail.com>


Project: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/commit/1c8d86e7
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/tree/1c8d86e7
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/diff/1c8d86e7

Branch: refs/heads/master
Commit: 1c8d86e75e32a36d98c627f7886d125a12693ac0
Parents: b5affe1
Author: Robert Kowalski <ro...@apache.org>
Authored: Thu Sep 3 16:05:47 2015 +0200
Committer: Robert Kowalski <ro...@apache.org>
Committed: Thu Sep 3 19:18:41 2015 +0200

----------------------------------------------------------------------
 tasks/couchserver.js | 5 +++++
 1 file changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb-fauxton/blob/1c8d86e7/tasks/couchserver.js
----------------------------------------------------------------------
diff --git a/tasks/couchserver.js b/tasks/couchserver.js
index 1cee4d8..faa8118 100644
--- a/tasks/couchserver.js
+++ b/tasks/couchserver.js
@@ -53,6 +53,11 @@ module.exports = function (grunt) {
       if (setContentSecurityPolicy) {
         var headerValue = "default-src 'self'; img-src 'self' data:; font-src 'self'; " +
                           "script-src 'self' 'unsafe-eval'; style-src 'self' 'unsafe-inline';";
+
+        if (options.contentSecurityPolicyHeader) {
+          headerValue = options.contentSecurityPolicyHeader;
+        }
+
         res.setHeader('Content-Security-Policy', headerValue);
       }