Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all articles
Browse latest Browse all 49076

Rails and Cordova together - No Content-Security-Policy meta tag found

$
0
0

@claudiocarmeli wrote:

I have been stuck for over a week on something really annoying to which I am sure there must be an easy solution to but I don't really know what to google for and cannot find the answers anywhere.

I have a simple Rails back-end serving JSON to an Ionic+Cordova+Angular front-end. The app works PERFECTLY on browsers. When I try it on the Galaxy5 also does. However, all PUT requests do send a message to the database but don't write anything! It's a security issue as I keep getting

No Content-Security-Policy meta tag found
However adding it does not fix it. Does anyone know WHY? I really need to fix this but have tried all things with no luck so far.

My config.xml looks like this

<meta http-equiv="Content-Security-Policy" content="
default-src *;
style-src * 'unsafe-inline';
script-src * 'unsafe-inline';
media-src *;
img-src * data:;"
/>

And I still get the same

"No Content-Security-Policy meta tag found. Please add one when using the cordova-plugin-whitelist plugin.", source: file:///android_asset/www/plugins/cordova-plugin-whitelist/whitelist.js (26)
I also tried to add that to my index.html but that didn't help. I know for a fact that other people are having the same issue and I am wondering if there is a simple solution to this so that I can go on with my experiments :slight_smile:

Thank you very much in advance and sorry for being long,
Kind regards,
Claudio

Posts: 4

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 49076

Trending Articles



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