Add OTP and scopes to login #546

Merged
jolheiser merged 5 commits from jolheiser/tea:token-scope into main 2024-02-14 16:49:29 +00:00
Owner

Resolves #542

Resolves #542
jolheiser added 1 commit 2023-04-20 03:59:21 +00:00
feat: add otp and scopes to login
Signed-off-by: jolheiser <john.olheiser@gmail.com>
All checks were successful
check-and-test / check-and-test (pull_request) Successful in 1m36s
a3e2879d4c
jolheiser force-pushed token-scope from a3e2879d4c to bbaf379554 2023-05-07 01:39:48 +00:00 Compare
Owner

we should store the scope of the token in the login struct, so if we exec sub-commands we can check if we have permission before we even call the ui

or should we lookup the token scope via api on each exec?
or just let it fail on insuficient permisions?

we should store the scope of the token in the login struct, so if we exec sub-commands we can check if we have permission before we even call the ui or should we lookup the token scope via api on each exec? or just let it fail on insuficient permisions?
Author
Owner

we should store the scope of the token in the login struct, so if we exec sub-commands we can check if we have permission before we even call the ui

or should we lookup the token scope via api on each exec?

I think we'd still need to look it up, as a user could use a token that was already created and thus we'd have no idea what perms existed. Alternatively at that point we could cache it somewhere so it's a one-time exec.

or just let it fail on insuficient permisions?

This sounds like a bad UX, I think we should avoid it if we can. At least if we can fail early it won't cost a network trip.

> we should store the scope of the token in the login struct, so if we exec sub-commands we can check if we have permission before we even call the ui > > or should we lookup the token scope via api on each exec? I think we'd still need to look it up, as a user could use a token that was already created and thus we'd have no idea what perms existed. Alternatively at that point we could cache it somewhere so it's a one-time exec. > or just let it fail on insuficient permisions? This sounds like a bad UX, I think we should avoid it if we can. At least if we can fail early it won't cost a network trip.
Author
Owner

@6543 Any further thoughts on this, or is this good at least as a stopgap for now?

@6543 Any further thoughts on this, or is this good at least as a stopgap for now?
jolheiser force-pushed token-scope from bbaf379554 to 025cebeb38 2023-09-18 15:58:49 +00:00 Compare
jolheiser added 1 commit 2023-09-18 16:01:46 +00:00
chore: make docs
Signed-off-by: jolheiser <john.olheiser@gmail.com>
All checks were successful
check-and-test / check-and-test (pull_request) Successful in 1m17s
ea9ca70efc
jolheiser added 1 commit 2023-11-14 02:04:45 +00:00
Merge branch 'main' into token-scope
All checks were successful
check-and-test / check-and-test (pull_request) Successful in 1m17s
cca7027767
6543 approved these changes 2024-01-27 21:12:44 +00:00
6543 added 1 commit 2024-01-27 21:12:52 +00:00
Merge branch 'main' into token-scope
All checks were successful
check-and-test / check-and-test (pull_request) Successful in 1m17s
92e115a28b
6543 requested review from Maintainers 2024-01-27 21:13:21 +00:00
jolheiser merged commit c8c8e9758b into main 2024-02-14 16:49:29 +00:00
jolheiser deleted branch token-scope 2024-02-14 16:49:31 +00:00
Sign in to join this conversation.
No description provided.