[Question] Enforce() returns false but expected true for ABAC & in operator
See original GitHub issueWant to prioritize this issue? Try:
What’s your scenario? What do you want to achieve? I am trying to check below policy on editor , But in both cases i am getting false.
Your model:
[request_definition]
r = sub, obj, act
[policy_definition]
p = sub, obj, act
[policy_effect]
e = some(where (p.eft == allow))
[matchers]
m = r.sub.Owner == r.obj.Owner && r.sub.Doc in(r.obj.Docs)
Your policy:
{Owner: 'alice', Doc: 1}, { Owner: 'alice', Docs: [1,2] }
{Owner: 'alice', Doc: 1}, { Owner: 'alice', Docs: [3,4]}
Your request(s):
{Owner: 'alice', Doc: 1}, { Owner: 'alice', Docs: [1,2] } ---> false (expected: true)
Issue Analytics
- State:
- Created 2 years ago
- Comments:16 (9 by maintainers)
Top Results From Across the Web
[Question] Enforce() returns false but expected true for ABAC ...
I am trying to check below policy on editor , But in both cases i am getting false. Your model: [request_definition] r =...
Read more >How to check if String ends with String - Stack Overflow
Complete the solution so that it returns true if the first argument (string) passed in ends with the 2nd argument (also a string)....
Read more >AWS global condition context keys
Works with Boolean operators. Use this key to check whether the request was sent using SSL. The request context returns true or false...
Read more >Polar Syntax - Oso Library Documentation
Polar parses the keywords true and false as boolean values. ... The not operator will succeed when its argument fails. ... person =...
Read more >Programming in Standard ML
We use a similar technique to implement matching against an iterated regular expression — we attempt to match the null string, but if...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
working on this
@Tapas059 we added the docs for “in” (https://casbin.org/docs/en/syntax-for-models#speical-grammer) but that’s mostly for Go, I will redirect it.