I am working on an application with a Java Spring Boot back-end and Angular 13 front-end.
Right now a token is set in the user's local storage when he logs in for the first time and expires after 30 days.
This has been working fine so far, but now I need to validate whether a user's license is valid while his session is active. Right now the license validation is executed during login, but since the session does not expire daily, the user does not have to log in every day.
Looking at other threads it has been suggested to set another item in the user's local storage that expires after 24 hours, once expired it should trigger the back-end to check whether the user's license is active and trigger related logic.
Would that be the right approach to solve this issue?
Thank you very much