diff --git a/packages/yoroi-extension/chrome/constants-mv2.js b/packages/yoroi-extension/chrome/constants-mv2.js index 61aaa9c22a..5f9c9a32c8 100644 --- a/packages/yoroi-extension/chrome/constants-mv2.js +++ b/packages/yoroi-extension/chrome/constants-mv2.js @@ -56,6 +56,7 @@ export function genCSP(request: {| // Analytics connectSrc.push('https://analytics.emurgo-rnd.com/'); + connectSrc.push('https://api2.amplitude.com/'); // wasm-eval is needed to compile WebAssembly in the browser // note: wasm-eval is not standardized but empirically works in Firefox & Chrome https://github.com/w3c/webappsec-csp/pull/293 diff --git a/packages/yoroi-extension/chrome/constants.js b/packages/yoroi-extension/chrome/constants.js index c47be3b06d..b200a5d394 100644 --- a/packages/yoroi-extension/chrome/constants.js +++ b/packages/yoroi-extension/chrome/constants.js @@ -27,6 +27,8 @@ export function genCSP(request: {| frameSrc.push('https://emurgo.github.io/'); frameSrc.push('https://www.youtube.com/') + // Analytics + connectSrc.push('https://analytics.emurgo-rnd.com/'); connectSrc.push('https://api2.amplitude.com'); // unsafe-inline is unfortunately required by style-loader (even in production builds) diff --git a/packages/yoroi-extension/chrome/manifest-mv2.development.js b/packages/yoroi-extension/chrome/manifest-mv2.development.js index c056727101..563d7155b1 100644 --- a/packages/yoroi-extension/chrome/manifest-mv2.development.js +++ b/packages/yoroi-extension/chrome/manifest-mv2.development.js @@ -19,6 +19,7 @@ export default (isDebug: boolean, shouldInjectConnector: boolean): * => buildMan additional: { 'connect-src': [ serverToPermission(Servers.Primary), + serverToPermission(Servers.Testnet), ], 'frame-src': [ POOLS_UI_URL_FOR_YOROI, diff --git a/packages/yoroi-extension/chrome/manifest-mv2.mainnet.js b/packages/yoroi-extension/chrome/manifest-mv2.mainnet.js index af1d7acccf..2b67f01a57 100644 --- a/packages/yoroi-extension/chrome/manifest-mv2.mainnet.js +++ b/packages/yoroi-extension/chrome/manifest-mv2.mainnet.js @@ -21,6 +21,7 @@ export default (isDebug: boolean, shouldInjectConnector: boolean): * => buildMan additional: { 'connect-src': [ serverToPermission(Servers.Primary), + serverToPermission(Servers.Testnet), ], 'frame-src': [ POOLS_UI_URL_FOR_YOROI, diff --git a/packages/yoroi-extension/scripts-mv2/connections.js b/packages/yoroi-extension/scripts-mv2/connections.js index f66967e4c2..4e90c5a506 100644 --- a/packages/yoroi-extension/scripts-mv2/connections.js +++ b/packages/yoroi-extension/scripts-mv2/connections.js @@ -20,6 +20,7 @@ const Ports = { const Servers = { // this allows connecting to multiple different backends for different currencies Primary: '*.yoroiwallet.com', + Testnet: '*.emurgornd.com', }; module.exports = {