-
Notifications
You must be signed in to change notification settings - Fork 24
I am not able to get this working for me, do you have a working example for same #6
Comments
Can you describe what you tried and what error message you saw? |
To add my token with session in redis , I wrore below code.
It able to add just user in redis with a session UUID , which I passed in redis ( req.jwtSession.user = user.toJSON();) Later at the time of logout I tried this then I am getting error:- "Error: Invalid session id" I am not sure how to pass session id to this. |
That error means that the request did not contain a valid JWT, or that the session had already expired or been removed from redis. If you |
In can see in "Redis Desktop manager" that session is available, console.log-- Just before logout One more things...I want to handle scenario like force browser close, how can I destroy my session in this case of browser close |
Can you also verify that you're passing the JWT on the logout request? That console.log info seems to show that the module did not find the JWT in the logout request. I would also log the data from the express request object to verify that you're passing the JWT in the query, body, or headers. |
yes, I am passing jwt token with each request using interceptor at client side auth.isAuthenticated() actually doing this validateJwt(req, res, next); Its validating JWT token Since I am not able to delete Redis session there are multiple entries in redis for same user. |
No description provided.
The text was updated successfully, but these errors were encountered: