Repository navigation
Fix acl check permission - #3618
supermafete wants to merge 6 commits into
Conversation
|
Can one of the admins verify this patch? To accept patch and trigger a build add comment ".ok\W+to\W+test." |
|
Can one of the admins verify this patch? |
3 similar comments
|
Can one of the admins verify this patch? |
|
Can one of the admins verify this patch? |
|
Can one of the admins verify this patch? |
|
Hello @supermafete, thank you for the pull request. I am personally not familiar with this part of the code base, but I'll try to find some time to review your changes. I think @ebarault @raymondfeng or perhaps even @alFReD-NSH may be more suited to review this change. The following pull request may be related to this problem too: #3293 |
|
There's no test cases here. Without one, we can't see if this is making any difference or not. Also the build is not passing and commits need to be cleaned up. |
|
Can one of the admins verify this patch? |
2 similar comments
|
Can one of the admins verify this patch? |
|
Can one of the admins verify this patch? |
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
|
This issue has been closed due to continued inactivity. Thank you for your understanding. If you believe this to be in error, please contact one of the code owners, listed in the |
|
|
||
| // Not really. We must find the first permission that matches our request | ||
| var new_candidate = acls.find((acl) => { | ||
| return ((acl.principalType === principalType) && (acl.principalId === principalId)); |
There was a problem hiding this comment.
I tried out this PR as a monkey patch on my system. I had to add this condition:
(acl.accessType === req.accessType)
otherwise the permissions check would do things like allow write access when only read access was granted.
Description
ACL.checkPermission is resolving the permission with highest score, no matter the principalType or principalId provided to the function.
Related issues
Checklist
guide