-
I'm trying to figure out a way to use web app as the authorization point into an Electron desktop app, so that user doesn't need to enter login/password again if they're already logged into the website, but instead just get redirected back to the desktop app via deep link with a auth success of some sort. Similar to how Spotify or Figma desktop apps work. What I tried
This approach is problematic, because
Thank you! |
Beta Was this translation helpful? Give feedback.
Answered by
igorlanko
Oct 18, 2024
Replies: 1 comment 3 replies
-
Did you manage to do what you wanted? |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yes, actually! Though it's been quite some time, the
refreshSession()
is definitely not a suitable method for deep linking.Instead, we need to get the
hashed_token
somehow, so that it's sent back to the app and the app creates a separate session withauth.verifyOtp()
.So what I'm doing is sending user to
site.com/auth/login?desktop=true
, they complete login, server takes the new session, gets the user email fromauth.getUser()
, and then completely unexpected (for me):