0

When i use chrome://inspect/#devices i got this error but struggling to solve it.

No Content-Security-Policy meta tag found. Please add one when using the cordova-plugin-whitelist plugin.
(anonymous function) @ console-via-logger.js:173
(anonymous function) @ whitelist.js:23
build @ cordova.js:53
require @ cordova.js:68
localRequire @ cordova.js:49
exports.mapModules @ cordova.js:1461
(anonymous function) @ cordova.js:1270
channel.join.f @ cordova.js:692
Channel.fire @ cordova.js:820
(anonymous function) @ cordova.js:1262
onScriptLoadingComplete @ cordova.js:1731
scriptLoadedCallback @ cordova.js:1748
(anonymous function) @ cordova.js:1702
28console-via-logger.js:173
No Content-Security-Policy meta tag found. Please add one when using the cordova-plugin-whitelist plugin.
Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
Mohan Gopi
  • 7,606
  • 17
  • 66
  • 117
  • 1
    Found a similar question: [this one](http://stackoverflow.com/questions/30212306/no-content-security-policy-meta-tag-found-error-in-my-phonegap-application) – sch Oct 16 '15 at 06:45
  • i have already checked this question but same error – Mohan Gopi Oct 20 '15 at 09:23

1 Answers1

0

You have to add a Content-Security-Policy meta tag in your index.html file :

<meta http-equiv="Content-Security-Policy" content="default-src *; style-src 'self' 'unsafe-inline'; script-src 'self' 'unsafe-inline' 'unsafe-eval'"/>

More info on the Content-Security-Policy meta tag : http://www.html5rocks.com/en/tutorials/security/content-security-policy/?redirect_from_locale=fr

Cordova doc about it : https://github.com/apache/cordova-plugin-whitelist#content-security-policy

Damien
  • 3,915
  • 1
  • 17
  • 18