A 2-year old keycloak-user list question w/o an answer:
- there’s a protected resource called Project
- and an owner - a Project Manager
- Each project manager has access to only their own projects (owner-only policy).
- Project Managers in turn report to one or more Portfolio Managers. A Portfolio Manager should be able to access all his/her project managers' projects (portfolio-manager policy).
Let’s assume the system design if flexible and this fact who are the Portfolio Managers for a particular Project Manager can be either kept inside Keycloak (but not as keycloak groups) or in the client app itself. How can this be implemented as a JavaScrtipt-based authorization policy in Keycloak? I guess the request can be injected with this info somehow but can’t figure it out from the docs.