You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by GitBox <gi...@apache.org> on 2021/08/11 07:22:01 UTC
[GitHub] [cordova-android] sawaca96 opened a new issue #1318: [10.0.1] cors error occurred
sawaca96 opened a new issue #1318:
URL: https://github.com/apache/cordova-android/issues/1318
# Bug Report
## Problem
### What is expected to happen?
after bump to android@10.0.1 from android@9.1.0, cors error occurred
I see the following Error when i run my App via device:
```
Access to XMLHttpRequest at 'https://xxxxxxxx' from origin 'https://localhost' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource
```
### What does actually happen?
this error occurred only device not emulator. emulator working well.
also in andorid@9.1.0 everything is well
### Environment, Platform, Device
<!-- In what environment, on what platform or on which device are you experiencing the issue? -->
galaxy tab 6, android 10
```
Cordova Packages:
cli: 10.0.0
common: 4.0.2
create: 3.0.0
lib: 10.0.0
common: 4.0.2
fetch: 3.0.1
serve: 4.0.0
Project Installed Platforms:
android: 10.0.1
ios: 6.2.0
Project Installed Plugins:
code-push: 3.0.1
cordova-plugin-advanced-http: 3.1.0
cordova-plugin-android-permissions: 1.1.2
cordova-plugin-androidx-adapter: 1.1.3
cordova-plugin-appcenter-analytics: 0.5.1
cordova-plugin-appcenter-crashes: 0.5.1
cordova-plugin-appcenter-shared: 0.5.1
cordova-plugin-code-push: 2.0.0
cordova-plugin-device: 2.0.3
cordova-plugin-dialogs: 2.0.2
cordova-plugin-file: 6.0.2
cordova-plugin-firebasex: 12.0.0-cli
cordova-plugin-googleplus: 8.5.2
cordova-plugin-inappbrowser: 5.0.0
cordova-plugin-navigationbar-color: 0.0.8
cordova-plugin-splashscreen: 6.0.0
cordova-plugin-statusbar: 2.4.3
cordova-plugin-wkwebviewxhrfix: 1.0.0
cordova-plugin-x-socialsharing: 6.0.3
cordova-plugin-zip: 3.1.0
es6-promise-plugin: 4.2.2
Environment:
OS: macOS 11.5.1 (20G80) (darwin 20.6.0) x64
Node: v12.18.2
npm: 6.14.5
```
### Version information
<!--
What are relevant versions you are using?
For example:
Cordova: Cordova CLI, Cordova Platforms, Cordova Plugins
Other Frameworks: Ionic Framework and CLI version
Operating System, Android Studio, Xcode etc.
-->
## Checklist
<!-- Please check the boxes by putting an x in the [ ] like so: [x] -->
- [x] I searched for existing GitHub issues
- [x] I updated all Cordova tooling to most recent version
- [x] I included all the necessary information above
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org
[GitHub] [cordova-android] toufiqpathan commented on issue #1318: [10.0.1] XMLHttpRequest cors error occurred
Posted by GitBox <gi...@apache.org>.
toufiqpathan commented on issue #1318:
URL: https://github.com/apache/cordova-android/issues/1318#issuecomment-920512727
Hi getting this error while loading the map
using android 10.1.1, please help me this error is blocker for me.
Access to XMLHttpRequest at 'https://maps.googleapis.com/maps/api/directions/json?origin=16.8218588%2C%2075.7139356&destination=-37.004771%2C%20174.78361&waypoints=&travelMode=DRIVING&drivingOptions=&key=xxxxxxxxxxxxxx from origin 'https://localhost' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org
[GitHub] [cordova-android] breautek commented on issue #1318: [10.0.1] XMLHttpRequest cors error occurred
Posted by GitBox <gi...@apache.org>.
breautek commented on issue #1318:
URL: https://github.com/apache/cordova-android/issues/1318#issuecomment-912796707
Is `'https://xxxxxxxx' ` is a remote server? If so, the server has to implement the CORS headers.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org
[GitHub] [cordova-android] jcesarmobile commented on issue #1318: [10.0.1] XMLHttpRequest cors error occurred
Posted by GitBox <gi...@apache.org>.
jcesarmobile commented on issue #1318:
URL: https://github.com/apache/cordova-android/issues/1318#issuecomment-919594969
Cordova-android 10 uses https by default instead of file for loading the assets. When using file, the app was not affected by Cors restrictions, but when using https/http it is, so you have to configure cors in your server to allow your origin, or set the app to use file scheme.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org
[GitHub] [cordova-android] msimons0 commented on issue #1318: [10.0.1] XMLHttpRequest cors error occurred
Posted by GitBox <gi...@apache.org>.
msimons0 commented on issue #1318:
URL: https://github.com/apache/cordova-android/issues/1318#issuecomment-935861752
Have you tried adding the following configuration to the config.xml file:
`<preference name="AndroidInsecureFileModeEnabled" value="true" />`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org
[GitHub] [cordova-android] jcesarmobile closed issue #1318: [10.0.1] XMLHttpRequest cors error occurred
Posted by GitBox <gi...@apache.org>.
jcesarmobile closed issue #1318:
URL: https://github.com/apache/cordova-android/issues/1318
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org