Fork me on GitHub
#yada
<
2018-10-07
>
grav16:10:15

Why is access control a special case in Yada? Why not implement it, as the Yada docs state in “12.2. Declaring policies across multiple resources”, namely walk the routing tree with a function that augments the resources?

grav16:10:52

Or am I maybe misunderstanding 12.2?

dominicm16:10:22

I don't understand the question. We use clojure walk and bidi to achieve that now.

grav16:10:06

Thinking about it, I think you’re right, I’m mixing up things. Of course you can add :access-control by walking the tree. What I’m after is, why at all have :access-control, when it’s just a matter of sending back yet another HTTP status code?

malcolmsparks16:10:42

There's quite a lot involved in access control. See the yada blog on authentication. Also, CORS pre-flight requests. Yada implements quite complex semantics from policy statements.