Skip to content

Commit ecee16b

Browse files
committed
Fix disqus CSP
Disqus loads it's embed config.js from its root domain (https://disqus.com). Our CSPs only allow subdomains (e.g.: https://codimd.disqus.com). This causes the disqus embedding to fail. This patch should fix this problem by adding https://disqus.com to the CSP setting. From a security perspective there is no real change. Since still the same parties are involved. Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
1 parent b40f14f commit ecee16b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/csp.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ var cdnDirectives = {
2323
}
2424

2525
var disqusDirectives = {
26-
scriptSrc: ['https://*.disqus.com', 'https://*.disquscdn.com'],
26+
scriptSrc: ['https://disqus.com', 'https://*.disqus.com', 'https://*.disquscdn.com'],
2727
styleSrc: ['https://*.disquscdn.com'],
2828
fontSrc: ['https://*.disquscdn.com']
2929
}

0 commit comments

Comments
 (0)