-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not working #4
Comments
Can you try to run this test: https://github.com/gin-contrib/authz/blob/master/authz_test.go ? The test actually uses the authz middleware and can get correct result ( |
They are being overwritten every time |
Thanks for the PR! |
One question, how can I allow all requests to a particular route? |
The following example allows any user to perform any action (GET, POST, etc.) on Model: [request_definition]
r = sub, obj, act
[policy_definition]
p = sub, obj, act
[role_definition]
g = _, _
[policy_effect]
e = some(where (p.eft == allow))
[matchers]
m = (g(r.sub, p.sub) || p.sub == "*") && keyMatch(r.obj, p.obj) && (r.act == p.act || p.act == "*") Policy:
|
@hsluoyz thanks |
When I added the middleware:
I get do get a 403 response but the request is not ended:
The text was updated successfully, but these errors were encountered: