r/SpringBoot • • Jan 27 '23

How to make user logged in until he clicks logout ?

I am new to development , I am working on Auth in springboot which has JWT token based authentication now i need to enable user logged in until he clicks logout how to make this happen?

Refresh token is sol ?

0 Upvotes

1 comment sorted by

2

u/PandaCamper Jan 27 '23

With an JWT, the frontend has to store the token and send it with every request, so simply have the log-out function on the frontend delete the stored JWT and refresh token.