Is your feature request related to a problem? Please describe.
The current authentication system doesn't provide optimal security and user experience. Users may be logged out too frequently or stay logged in for too long, posing security risks.
Describe the solution you'd like
Enhance the frontend authentication system to use refresh and access tokens for improved security.
[ ] Update the axios instance to include an interceptor for handling access tokens
[ ] Implement secure storage of tokens (e.g., HttpOnly cookies for refresh tokens, memory for access tokens)
[ ] Create a mechanism to refresh the access token when it expires
[ ] Update the login function in LoginModal to handle both access and refresh tokens
[ ] Modify the useProfile hook to use the new token system
[ ] Update logout functionality to clear both tokens
Is your feature request related to a problem? Please describe.
The current authentication system doesn't provide optimal security and user experience. Users may be logged out too frequently or stay logged in for too long, posing security risks.
Describe the solution you'd like
Enhance the frontend authentication system to use refresh and access tokens for improved security.
Describe alternatives you've considered
Additional context