Skip to content

Commit

Permalink
fix(csp): use wildcard for sentry.io for matching subdomains (#1775)
Browse files Browse the repository at this point in the history
  • Loading branch information
emmenko authored Oct 2, 2020
1 parent 08f79ff commit 57be02b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/beige-beers-join.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@commercetools-frontend/mc-html-template': patch
---

Fix default CSP `connect-src` directive to match all attempts to load from any subdomain of `sentry.io`
3 changes: 2 additions & 1 deletion packages/mc-html-template/src/process-headers.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,8 @@ const processHeaders = (applicationConfig) => {
'clientstream.launchdarkly.com',
'events.launchdarkly.com',
'app.getsentry.com',
'sentry.io',
// Match all attempts to load from any subdomain of `sentry.io`
'*.sentry.io',
'www.google-analytics.com',
].concat(
isMcDevEnv ? ['ws:', 'localhost:8080', 'webpack-internal:'] : []
Expand Down

1 comment on commit 57be02b

@vercel
Copy link

@vercel vercel bot commented on 57be02b Oct 2, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.