Refactor authentification and authorization
- 主要言語
- TypeScript
- スター
- 0
- フォーク
- 0
- 平均マージ
- 7日 3時間
- マージ済み PR(30日)
- 2
説明
After the user is logged in, all the assigned roles of the user are storage in the browser's sessionStorage and only checked on the client-side. This is bad practice. Anyone who has a user account is able to manipulate the sessionStorage and add/remove roles freely. Or they can send a REST request to any endpoint. As long as they have a valid token, they can completely bypass the current auth management. Furthermore, whenever the token lifetime runs out, the user won't be logged off automatically, but has to send a request to a REST endpoint (e.g. register a patient) before being forwarded to the log in mask.
TODO:
- Remove storing of permissions/roles in sessionStorage
- add checks to every secure endpoint
- add visible timer for token lifetime
- refresh token lifetime after mouse movement
- automatically forward user to login mask after token lifetime runs out
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
評価
この issue はまだ評価されていません。