Merge pull request #5102 from betagouv/fix/4995
Fix Safari and Firefox compatibility for mapbox-gl js
This commit is contained in:
commit
aad44dbac8
1 changed files with 2 additions and 2 deletions
|
@ -1,6 +1,6 @@
|
|||
Rails.application.config.content_security_policy do |policy|
|
||||
# Whitelist image
|
||||
policy.img_src :self, "*.openstreetmap.org", "static.demarches-simplifiees.fr", "*.cloud.ovh.net", "stats.data.gouv.fr", "*", :data
|
||||
policy.img_src :self, "*.openstreetmap.org", "static.demarches-simplifiees.fr", "*.cloud.ovh.net", "stats.data.gouv.fr", "*", :data, :blob
|
||||
# Whitelist JS: nous, sendinblue et matomo
|
||||
# miniprofiler et nous avons quelques boutons inline :(
|
||||
policy.script_src :self, "stats.data.gouv.fr", "*.sendinblue.com", "*.crisp.chat", "crisp.chat", "*.sibautomation.com", "sibautomation.com", :unsafe_eval, :unsafe_inline, :blob
|
||||
|
@ -11,7 +11,7 @@ Rails.application.config.content_security_policy do |policy|
|
|||
policy.connect_src :self, "wss://*.crisp.chat", "*.crisp.chat", "*.demarches-simplifiees.fr", "in-automate.sendinblue.com", "app.franceconnect.gouv.fr", "sentry.io", "geo.api.gouv.fr", "api-adresse.data.gouv.fr", "openmaptiles.geo.data.gouv.fr", "openmaptiles.github.io", "tiles.geo.api.gouv.fr"
|
||||
# Pour tout le reste, par défaut on accepte uniquement ce qui vient de chez nous
|
||||
# et dans la notification on inclue la source de l'erreur
|
||||
policy.default_src :self, :data, :report_sample, "fonts.gstatic.com", "in-automate.sendinblue.com", "player.vimeo.com", "app.franceconnect.gouv.fr", "sentry.io", "static.demarches-simplifiees.fr", "*.crisp.chat", "crisp.chat", "*.crisp.help", "*.sibautomation.com", "sibautomation.com", "data"
|
||||
policy.default_src :self, :data, :blob, :report_sample, "fonts.gstatic.com", "in-automate.sendinblue.com", "player.vimeo.com", "app.franceconnect.gouv.fr", "sentry.io", "static.demarches-simplifiees.fr", "*.crisp.chat", "crisp.chat", "*.crisp.help", "*.sibautomation.com", "sibautomation.com", "data"
|
||||
if Rails.env.development?
|
||||
# Les CSP ne sont pas appliquées en dev: on notifie cependant une url quelconque de la violation
|
||||
# pour détecter les erreurs lors de l'ajout d'une nouvelle brique externe durant le développement
|
||||
|
|
Loading…
Reference in a new issue