Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 70612

No problem with content-security-policy on devices but errors on local serve

$
0
0

@griffin wrote:

Work's perfectly on android, ios, & fire devices.
Can't click some listings. On local serve.

What the heck am I doing wrong??

`http://localhost:*;

script-src 'self' 'unsafe-inline' 'unsafe-eval'
  https://*.firebaseio.com
  http://localhost:*;

connect-src 'self' 'unsafe-inline'
  https://XXXXXXXXXXXX.herokuapp.com
  https://*.firebaseio.com
  wss://*.firebaseio.com
  ws://localhost:*
  https://auth.firebase.com;

frame-src
  gap://ready
  https://*.stripe.com
  https://*.firebaseio.com;

font-src
  http://localhost:*;

img-src 'self'
  data:
  https://*.stripe.com
  https://fbcdn-profile-a.akamaihd.net
  https://res.cloudinary.com; ">`

The errors shown:

Refused to connect to 'https://checkout.stripe.com/api/outer/manhattan?key=pk_test_JcKZLhGQkLgYWszvBD4PPvVi' because it violates the following Content Security Policy directive: "connect-src 'self' 'unsafe-inline'
https://safe-atoll-5123.herokuapp.com
https://*.firebaseio.com
wss://*.firebaseio.com
ws://localhost:*
https://auth.firebase.com".
Checkout.shouldUseManhattan @ checkout.js:2
ionic.bundle.js:21162 Error: Failed to execute 'open' on 'XMLHttpRequest': Refused to connect to 'https://checkout.stripe.com/api/outer/manhattan?key=pk_test_JcKZLhGQkLgYWszvBD4PPvVi' because it violates the document's Content Security Policy.
at Error (native)
at Checkout.shouldUseManhattan (https://checkout.stripe.com/checkout.js:2:16855)
at Checkout.shouldUseManhattan (https://checkout.stripe.com/checkout.js:2:12444)
at new Checkout (https://checkout.stripe.com/checkout.js:2:13425)
at App.configure (https://checkout.stripe.com/checkout.js:2:6021)
at Object.configure (https://checkout.stripe.com/checkout.js:2:3780)
at new <anonymous> (http://localhost:8100/js/controllers/specificListingController.js:53:37)
at invoke (http://localhost:8100/lib/ionic/js/ionic.bundle.js:13282:17)
at Object.instantiate (http://localhost:8100/lib/ionic/js/ionic.bundle.js:13290:27)
at http://localhost:8100/lib/ionic/js/ionic.bundle.js:17846:28

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 70612

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>