question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Plugin does not define it's own whitelist needs

See original GitHub issue

Many people (incl. me) expect that Cordova plugins define their own whitelist needs in the plugin.xml so they don’t have to worry about every plugin separately.

This plugin does not do that, and does not explain this clearly to the users either.

plugin.xml should include something along the lines of:

<platform name="android">
  <config-file target="res/xml/config.xml" parent="/*">
    <access origin="http://*.google-analytics.com"/>
    <access origin="https://*.google-analytics.com"/>
  </config-file>
</platform>
<platform name="ios">
  <config-file target="res/xml/config.xml" parent="/*">
    <access origin="http://*.google-analytics.com"/>
    <access origin="https://*.google-analytics.com"/>
  </config-file>
</platform>

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
victorsosacommented, Jul 8, 2016

I suppose <access > is deprecated and we should use whitelist instead.

<allow-navigation href="http://*.google-analytics.com" />
<allow-navigation href="https://*.google-analytics.com" />

base on the whitelist https://cordova.apache.org/docs/en/latest/reference/cordova-plugin-whitelist/index.html#navigation-whitelist

cordova >4.0.0

0reactions
victorsosacommented, Jul 16, 2016

I tested this out and none change need to be done in the code.

Read more comments on GitHub >

github_iconTop Results From Across the Web

cordova whitelist doesn't work in android
hey , i use the cordova android platform cli to create one android project and it unexpectedly add the cordova-plugin-whitelist? I used to...
Read more >
Whitelist Guide - Apache Cordova
While it is possible to implement your own whitelist plugin, it is not recommended unless your app has very specific security policy needs....
Read more >
peerDependencies and devDependencies auto whitelist. · ...
I'd expect that if the devDependencies is listed in the peerDependencies I don't need to add it explicitly in the whitelist.
Read more >
cannot find symbol "import org.apache.cordova.Whitelist;" · ...
Problem. The plugin is not working with Cordova Android 10 anymore because Whitelist was renamed to Allowlist. What is expected to happen? The ......
Read more >
Whitelisting IP address not working
I want my clients to be able to access the site without logging in, so that they can see what a non-logged-in visitor...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found