Checking validity of tokens in isAuthenticated #185
WJGoldsworthy
started this conversation in
General
Replies: 1 comment 2 replies
-
isAuthenticated only checks if you have the user data on the sessionKey (user by default), what you store there is up to you so if you do store something with an expiration data you need to manually check if it's expired. Another option could be to use the expiration data of the access token as the expiration of the session cookie, but if you have a refresh token this means you will lose the refresh token, so you probably want to keep the cookie around and verify the validity of the access token yourself. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am using an implementation of remix-auth with an OktaStrategy. I was using the isAuthenticated function which was returning me the details of the user in the session along with the accessToken even though the access token was expired.
Is there or should there be any check during this that checks the validity/expiration of the token and session?
Beta Was this translation helpful? Give feedback.
All reactions