Google javascript Oauth related 404 in Cordova/Intel Xdk -


i have strange error seem error 404 while executing google's javascript client. error happens on device; not in emulation.

i using

  • intel's xdk v2807
  • html5+cordova app
  • cordova cli v.5.1.1
  • inappbrowser v1.1.0
  • geolocation, statusbar, device, splashscreen plugins loaded
  • using nexus 6p; marshmallow dut

i'm using google's template oauth: sample authorization

i have whitelisted app's networking, "turning off" security:

content security policy restrictions removed:

<meta http-equiv="content-security-policy"           content="default-src *;                    style-src * 'self' 'unsafe-inline' 'unsafe-eval';                    script-src * 'self' 'unsafe-inline' 'unsafe-eval';"> 

access origins anywhere (added in config.xml)

<allow-navigation href="*" /> <allow-intent href="*" /> <access origin="*" /> 

setting above csp , allowances in config got me past original frustrations having error 404 on: (failed load resource come in chrome javascript console) [this error didn't appear in emulation; on device]

<script src="https://apis.google.com/js/client.js?onload=handleclientload"></script> 

this error receive in chrome javascript console:

get https://accounts.google.com/o/oauth2/postmessagerelay?parent=file%3a%2f%2f 404 (not found)re @ cb=gapi.loaded_0:508_.xw @ cb=gapi.loaded_0:512(anonymous function) @ cb=gapi.loaded_0:531(anonymous function) @ client.js?onload=handleclientload:5x @ client.js?onload=handleclientload:8oa @ client.js?onload=handleclientload:5t @ client.js?onload=handleclientload:7r.(anonymous function).b @ client.js?onload=handleclientload:7r.(anonymous function) @ client.js?onload=handleclientload:7d.(anonymous function) @ client.js?onload=handleclientload:7(anonymous function) @ cb=gapi.loaded_0:1 

while debugging looks i'm receiving error inside checkauth function:

function checkauth() { gapi.auth.authorize({client_id: clientid, scope: scopes, immediate: true}, handleauthresult);} 

it appears it's kind of location problem. suppose that's due fact while on phone it's running pages file's rather webserver serve's pages website ~ emulator doing.if that's issue; i'm not sure how correct it.

any or direction appreciated.


Comments

Popular posts from this blog

SVG stroke-linecap doesn't work for circles in Firefox? -

routes - Laravel 4 Wildcard Routing to Different Controllers -

cross browser - XSLT namespace-alias Not Working in Firefox or Chrome -