Hi, I understand that one can map the resource pol...
# help
d
Hi, I understand that one can map the resource policies 1:1 to each data set, Could the cerbos pdp respond to questions get all dataset user xxx has access to?
a
Hi - yes this is what the query plan is used for https://docs.cerbos.dev/cerbos/latest/api/#resources-query-plan
Rather than giving you back a ALLOW or DENY, Cerbos will give you back a set of conditions to apply to your data lookup (eg SQL WHERE clause) to return just the records a user would have a specific permission to
We also have some reference adapters avaliable https://github.com/cerbos/query-plan-adapters
d
So Cerbos does not hold the actual metadata of the datasets (id,owner,createAT) in a postgres table for example?
a
Correct - Cerbos is a stateless policy decision point (some background https://www.cerbos.dev/blog/the-importance-of-stateless-architecture-in-authorization-systems)
🙌 1
✅ 1

https://www.youtube.com/watch?v=-TROtUh5wvkâ–¾

d
Thanks for your reply if i would like to map every dataset to specific policy (one-to-one) i would pass the id relationship to the policy it applies under the
condition:
match:
expr:
correct?
a
Yes that would be one approach