Merge pull request #762 from sharetribe/add-csp-urls

Allowed CSP URLs
This commit is contained in:
Vesa Luusua 2018-03-14 17:54:34 +02:00 committed by GitHub
commit f3d83b83fc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -27,6 +27,7 @@ module.exports = (reportUri, enforceSsl, reportOnly) => {
const loremPixel = 'https://lorempixel.com/';
const placeholder = 'https://via.placeholder.com/';
const googleAnalytics = 'https://www.google-analytics.com/';
const googleAnalyticsDoubleClick = 'https://stats.g.doubleclick.net/';
const googleMaps = 'https://maps.googleapis.com/';
const googleStaticCsi = 'https://csi.gstatic.com/';
const googleStaticFonts = 'https://fonts.gstatic.com/';
@ -64,6 +65,8 @@ module.exports = (reportUri, enforceSsl, reportOnly) => {
// enabled.
scriptSrc.push(googleAnalytics);
imgSrc.push(googleAnalytics);
imgSrc.push(googleAnalyticsDoubleClick);
connectSrc.push(googleAnalytics);
}
if (sentryClientEnabled) {
connectSrc.push(sentryApi);