Hi, is there a recommended way to enforce all role...
# help
w
Hi, is there a recommended way to enforce all roles are present, instead of it being a conditional OR? e.g.
Copy code
roles:
        - USER
        - MANAGER
Make it so that the principal must have roles "USER" AND "MANAGER" instead of "USER" OR "MANAGER" Thanks
d
Hi Will, It is a workaround. The idea is to check the presence of both roles in the condition expression.
Copy code
roles:
        - USER
        - MANAGER
  condition:
     match:
        expr: ["USER", "MANAGER"].isSubset(P.roles)
If you want to do the same with derived roles, use
runtime.effectiveDerivedRoles
.
gratitude thank you 1