-
Notifications
You must be signed in to change notification settings - Fork 603
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
this.session.requireAuthentication is returning false on a page refresh, even though user is already authenticated #2710
Comments
Hi 👋 What We've had reports regarding similar issue that was related to Please visit this thread #2533 as your issue seems very similar to that one. Feel free to reach out if that doesn't help 👍 |
We are using Thanks for your suggestions @BobrImperator. I'll see if updating |
We are experiencing this issue as well. Currently running:
|
@nurmuhammadsiratseequent are you using the cookie store? and are you also using I wonder if this has anything to do with the release of Edit: I tried to switch to LocalStorage and the same thing happens. I have no idea what's going on 🤷♂️ |
Hi @gzurbach. No, I'm using localStorage with a custom authenticator. I'm also not using |
I'm having the same problem, cookies based store
and getting this error
|
This problem is happening when using JWT authenticator with |
@BobrImperator Upgrading to |
Could you please find out if you can reproduce this in a fresh project? |
Unsure if this belongs here, but I am currently also experiencing issues with Our CI is running tests with the cypress test framework. What seems to happen is that the localStorage key It seems that multiple visits in rapid succession to a route with What I found out by stresstesting: I am not sure how to setup a fresh project for all of this.
|
In ESA 4.2.2, I can call
this.session.requireAuthentication(transition, 'login')
on a protected route in thebeforeModel
and this will returntrue
if a user has already authenticated. I can verify this by looking at localStorage and seeing that the user's token is persisted there. If I were to manually refresh the page on this protected route or go to the same route in another tab, I will remain authenticated.We're upgrading from 4.2.2 to 5.0.0 (and eventually 6.0.0). Now, in ESA 5.0.0, this call is returning
false
on a refresh after the user has previously authenticated. It will transition the user to the login route. However I can see that the auth data is still persisted in the localStorage keyember_simple_auth-session
.I have verified that this behaviour is also happening in 6.0.0.
The text was updated successfully, but these errors were encountered: