Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(cli): Allow to configure access origin on cordova config.xml #5134

Merged
merged 5 commits into from Oct 27, 2021
Merged

feat(cli): Allow to configure access origin on cordova config.xml #5134

merged 5 commits into from Oct 27, 2021

Conversation

Dante1349
Copy link
Contributor

@Dante1349 Dante1349 commented Oct 14, 2021

Hey,

i reecognized that the access origins where hard coded here, but i wanted to restrict the access origins because we are using cordova-plugin-inappbrowser which therefore can load any url.

@jcesarmobile
Copy link
Member

According to the own plugin docs, cordova-plugin-inappbrowser is not subject to the whitelist restrictions:
https://github.com/apache/cordova-plugin-inappbrowser/blob/master/README.md#windowopen

Can you provide a sample app where the cordova-plugin-inappbrowser respects the whitelist?

@jcesarmobile jcesarmobile added the needs reply needs reply from the user label Oct 14, 2021
@Dante1349
Copy link
Contributor Author

Dante1349 commented Oct 14, 2021

@jcesarmobile you are right, I didn't know that. But should't the access orgin list still be configurable?

@Ionitron Ionitron removed the needs reply needs reply from the user label Oct 14, 2021
Copy link
Member

@jcesarmobile jcesarmobile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've changed the name to accessOrigins as it populates access tags as allowedHosts could be confused with allow-navigation.
Also improved the description and fixed a few bugs and improved the resulting formatting, and more importantly, default to <access origin="*" /> if the config is not present so it's not a breaking change for existing users.

@jcesarmobile jcesarmobile changed the title Added access origin to capacitor cordova config.xml generation feat(cli): Allow to configure access origin on cordova config.xml Oct 27, 2021
@jcesarmobile jcesarmobile merged commit 0841a09 into ionic-team:main Oct 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants