Comments (16)
Further research thanks to a colleague revealed, that window.handleOpenURL method was also being invoked when the popup window showed a blank web page.
With some experimenting I was able to find the solution, which is a timeout in handleOpenURL function.
window.handleOpenURL = function (url) {
window.setTimeout(function () {
PKCEClient.onRedirectUri(url);
}, 100);
}
from auth0-cordova.
yes, if I reset the simulator (delete all settings) I can login the first time with google account. Then if I log out, and even if I remove the app and reinstall it, it gets stuck on the blank page :S
I am now testing with Native auth0 client, I have set team id and bundle id in client settings, but nothing seems to help.
from auth0-cordova.
update: we checked the auth0 log and there is a record of a successful login
therefore, this must be a problem when safariViewController tries to automatically redirect back to the app, when credentials are already available.
from auth0-cordova.
Can you check if the "Client Type" is selected as "Native" in Dashboard > Clients > Your Client Name > Settings
from auth0-cordova.
Thanks. It is not, I am not sure if I can change that on the old client (currently running in production :( ), will certainly do on the new one. Hopefully it will solve the problem, though I don't really see how that is connected :) The problem only appears on iOs and only when client has been logged in with the same social provider before.
from auth0-cordova.
@gregor-srdic in iOS does it work when the user is not previously logged in?
If not, please check that you installed the plugins detailed in the README correctly. Since cordova plugins tends to be a bit brittle I'd recommend removing the iOS platform and re-adding it.
from auth0-cordova.
after more research I found out that if I sign out of my google account in safari, I can login in cordova app again, first time.
And further, cordova app sign in always works if i sign into two or more google accounts in safari.
Therefore this must be an issue with automatic login with google account that occurs if user has previously logged in with single google account.
from auth0-cordova.
Does anyone have anything to add to this? It seems painful to ask users to delete safari cookies and web data every time they log out and want to log back in :S
from auth0-cordova.
SafariViewController
does not dismiss and callbacks are not running. The logs in the Auth0 dashboard show successful logins and signups.
from auth0-cordova.
@MT-- based on the screenshot your problem does not seem the same, I would say you have a problem with callback to the application. Perhaps you should try removing and re-ading the cordova-plugin-customurlscheme plugin and be careful about lower case like #38
from auth0-cordova.
from auth0-cordova.
Further research: Also if I revoke access to the application in google/facebook account, I can normally log in once again.
from auth0-cordova.
In phonegap build the same issue occurred for me.
SafariViewController does not dismiss and callbacks are not running. The logs in the Auth0 dashboard show successful logins and signups.
I tried setTimeout function in window.handleOpenURL but it is not work for me.
i tried deeplink plugin instead of color schema url also.
from auth0-cordova.
Hi @gregor-srdic I'm having the same problem that you were having. Fb is working fine but when trying to sign in with Gmail, the first time it's 👌 , but once the user is logged it shows me the Website Name. I tried with your solution but still not working. Do you have any news about it?
Thanks
from auth0-cordova.
I have the exact same issue :(
from auth0-cordova.
I was able to temporarily solve this for iOS by 'Erasing all Settings and Contents' from the Simulator and running the emulator again from scratch.
Must be some kind of cache that somehow persists even after you quit the simulator?
from auth0-cordova.
Related Issues (20)
- Handling errors in redirect uri HOT 1
- Capacitor support HOT 13
- onRedirectUri faulty behavior after first login HOT 8
- Module not found: Error: Can't resolve 'crypto' in 'C://mypc/path/node_module/@auth0\cordova\src' HOT 1
- Angular support HOT 4
- Login screen hangs after entering credentials HOT 9
- Refresh tokens HOT 6
- iOS social provider signout problem HOT 3
- Custom Webpack is not used when using livereload on cordova run HOT 6
- Sign in with Apple - error on callback HOT 22
- Universal and Deep link support for iOS and Android HOT 3
- Use ASWebAuthenticationSessionManager with cordova HOT 4
- New Version Release HOT 1
- Cannot read properties of undefined (reading 'open') HOT 1
- net: ERR_UNKNOWN_URL_SCHEME with targetSdkVersion 30 HOT 11
- loading icon keeps spinning after social sign in using ionic V3 app on Android
- Could not load module crypto HOT 3
- New Release? HOT 1
- Login with Google is not asking the account to use HOT 2
- SafariViewController Closes before user can save or update password HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from auth0-cordova.