-
Notifications
You must be signed in to change notification settings - Fork 67
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
feat: Authorization token storage #50
Comments
Hey, @RodolfoSilva It's a great idea we have done an investigation and here is a detailed analysis of this issue. In the context of Mirai (server-driven UI framework for Flutter), there are two main challenges, one is to authorize the right client to retrieve UI resources and the other is to pursue the right resource of user-specific data inside the user interfaces. For instance, let's skip authorizing the accessibility of Mirai interface templates, then here is the list of challenges we have.
Now let’s discuss what are the possible ways in which we can achieve this functionality in Mirai.
After this detailed analysis, we have come up with this solution that we can use |
I think if we add the ability to add new custom actions like we do with widgets, it gives more power to the user to decide how they want to use their local storage or something else. Mirai now supports receiving a Dio instance, this allows the user to implement their own authorization strategy and even invalidate the authorization. But I think the main purpose of making this feature possible is to provide a way to register new custom actions like we did for widgets. |
Description
We need a way to persist and destroy the passkey on the device to allow apps that have authentication to be able to persist the passkey locally and avoid the user having to provide credentials again.
Perhaps a simple encrypted key-value storage will solve this use case.
And also some way to always send this data in the request to the server, through the header perhaps.
Requirements
Additional Context
This will unlock advanced features when the app needs to keep some data locally to be used in future accesses.
Maybe it's just a feature to store a bearer token locally and send it every time the app requests something from the server.
The text was updated successfully, but these errors were encountered: