Skip to content

Commit

Permalink
Merge pull request #28 from sequra/fix/inline-script-blocked-at-checkout
Browse files Browse the repository at this point in the history
Enable csp report_only mode to not block inline script in the sequra …
  • Loading branch information
m1k3lm authored Sep 25, 2024
2 parents 97d3433 + 6db68bf commit 6ed5af0
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 20 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"pagos",
"magento2"
],
"version": "2.5.1",
"version": "2.5.2",
"license": "MIT",
"authors": [
{
Expand Down
12 changes: 10 additions & 2 deletions etc/config.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Store:etc/config.xsd">
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Store:etc/config.xsd">
<default>
<csp>
<mode>
<storefront>
<report_only>1</report_only>
</storefront>
</mode>
</csp>
<payment>
<sequra_payment>
<debug>1</debug>
Expand All @@ -20,4 +28,4 @@
</sequra_payment>
</payment>
</default>
</config>
</config>
32 changes: 16 additions & 16 deletions etc/csp_whitelist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,34 +3,34 @@
<policies>
<policy id="img-src">
<values>
<value id="sequra-sandbox-cdn" type="host">https://sandbox.sequracdn.com</value>
<value id="sequra-production-cdn" type="host">https://live.sequracdn.com</value>
<value id="sequra-sandbox-api" type="host">https://sandbox.sequrapi.com</value>
<value id="sequra-production-api" type="host">https://live.sequrapi.com</value>
<value id="sequra-sandbox-cdn" type="host">sandbox.sequracdn.com</value>
<value id="sequra-production-cdn" type="host">live.sequracdn.com</value>
<value id="sequra-sandbox-api" type="host">sandbox.sequrapi.com</value>
<value id="sequra-production-api" type="host">live.sequrapi.com</value>
</values>
</policy>
<policy id="script-src">
<values>
<value id="sequra-sandbox-cdn" type="host">https://sandbox.sequracdn.com</value>
<value id="sequra-production-cdn" type="host">https://live.sequracdn.com</value>
<value id="sequra-sandbox-api" type="host">https://sandbox.sequrapi.com</value>
<value id="sequra-production-api" type="host">https://live.sequrapi.com</value>
<value id="sequra-sandbox-cdn" type="host">sandbox.sequracdn.com</value>
<value id="sequra-production-cdn" type="host">live.sequracdn.com</value>
<value id="sequra-sandbox-api" type="host">sandbox.sequrapi.com</value>
<value id="sequra-production-api" type="host">live.sequrapi.com</value>
</values>
</policy>
<policy id="connect-src">
<values>
<value id="sequra-sandbox-cdn" type="host">https://sandbox.sequracdn.com</value>
<value id="sequra-production-cdn" type="host">https://live.sequracdn.com</value>
<value id="sequra-sandbox-api" type="host">https://sandbox.sequrapi.com</value>
<value id="sequra-production-api" type="host">https://live.sequrapi.com</value>
<value id="sequra-sandbox-cdn" type="host">sandbox.sequracdn.com</value>
<value id="sequra-production-cdn" type="host">live.sequracdn.com</value>
<value id="sequra-sandbox-api" type="host">sandbox.sequrapi.com</value>
<value id="sequra-production-api" type="host">live.sequrapi.com</value>
</values>
</policy>
<policy id="frame-src">
<values>
<value id="sequra-sandbox-cdn" type="host">https://sandbox.sequracdn.com</value>
<value id="sequra-production-cdn" type="host">https://live.sequracdn.com</value>
<value id="sequra-sandbox-api" type="host">https://sandbox.sequrapi.com</value>
<value id="sequra-production-api" type="host">https://live.sequrapi.com</value>
<value id="sequra-sandbox-cdn" type="host">sandbox.sequracdn.com</value>
<value id="sequra-production-cdn" type="host">live.sequracdn.com</value>
<value id="sequra-sandbox-api" type="host">sandbox.sequrapi.com</value>
<value id="sequra-production-api" type="host">live.sequrapi.com</value>
</values>
</policy>
</policies>
Expand Down
2 changes: 1 addition & 1 deletion etc/module.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
<module name="Sequra_Core" setup_version="2.5.1">
<module name="Sequra_Core" setup_version="2.5.2">
<sequence>
<module name="Magento_Catalog"/>
<module name="Magento_ConfigurableProduct"/>
Expand Down

0 comments on commit 6ed5af0

Please sign in to comment.