Hi authZ-crew,
Do you have any best practices/tips for scenarios where in the App, a user is able to generate it’s own API tokens with authorizations that can only be a subset of their own rights.
1) when creating the api token with a certain scope, we can ask cerbos whether what they’re trying to generate is ok. Then when the token is used, we can blindly use the token + its scope as Principle
And/or
2) we let the user create any api token they like with whatever scope they wish.
Once the token is used, we send both the token-scope (untrusted) and the backing user in the principle. But then we should do some form of double authz in cerbos on both the real user and the token attributes? How would that look in your opinion?
Any thoughts?