Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Access and Refresh Key Management in Frontend Login Implementation #1508

Open
derneuere opened this issue Dec 30, 2024 · 0 comments
Open
Labels
enhancement New feature or request tech-debt

Comments

@derneuere
Copy link
Member

Description:
The current frontend login implementation has an issue with the handling of the access and refresh keys:

Access Key Expiration: The Access Key expires after five minutes.
Expected Behavior: The Access Key should be refreshed proactively based on its timestamp before expiration using the Refresh Key.

Current Behavior:
We let the Access Key expire.
On the first "Unauthorized" response, we then refresh the Access Key.
If the refresh attempt fails multiple times, the user is logged out. Otherwise, everything continues to work as expected.

Steps to Improve:
Implement proactive Access Key refresh logic that checks the expiration timestamp.
Update the logic to refresh the Access Key before it expires, avoiding the need to handle "Unauthorized" responses.
Ensure fallback logic still gracefully handles cases where refresh attempts fail.

Impact:
Proactive handling will reduce unnecessary "Unauthorized" responses and improve user experience by minimizing disruptions.

@derneuere derneuere added enhancement New feature or request tech-debt labels Dec 30, 2024
@derneuere derneuere mentioned this issue Dec 30, 2024
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request tech-debt
Projects
None yet
Development

No branches or pull requests

1 participant