I currently have the following code in my cordova+crosswalk android app that successfully lets me get cookies that have come in via the webviews xmlhttprequest:
XWalkCookieManager cookieManager = new XWalkCookieManager();
Where
http://mydomain is the domain the javascript makes external calls to.
Obviously though in the webview, document.cookie does not return the above cookie, because the webview is in a file:// domain not
http://mydomain.
So what I want to do is use cookieManager to set a cookie that will be synchronously viewable in the webview via document.cookie. I have tried all of these:
cookieManager.setAcceptCookie(true);
cookieManager.setAcceptFileSchemeCookies(true);
cookieManager.setCookie("",someCookie);
cookieManager.setCookie("file://",someCookie);
cookieManager.setCookie("file:///",someCookie);
cookieManager.setCookie("file:///android_asset",someCookie);
cookieManager.setCookie("file:///android_asset/www",someCookie);
But none of those seem to work. Is there a particular cookie domain i can use that will match the webview so it can see the cookie via document.cookie?