Details
-
Story
-
Status: Closed (View Workflow)
-
P2
-
Resolution: Done
-
None
-
None
-
-
CP: sprint 125, CP: sprint 126
-
5
-
Core: Platform
Description
mod-permissions change to fix FOLIO-2582.
This PR makes a check against permissions when they are added to a user and when permissions (sets) are updated.
The behavior until now has been that if the operating user had perms.users.item.post, perms.users.item.put, any permission could be granted to the request user (which may be the same as the operating user). Also, if operating user had permission perms.permissions.item.put, permissions for users could also be changed.
This PR will change that, so that (by default), only permissions that are already owned by the operating
user can be assigned to the request user (the user in the path component).
The check works as follows.
1. If no user id , no operating user (basically no token). So an unauthenticated system, the operation is allowed.
2. if permission starts with okapi. and operating user permissions and module permissions doesn't contain perms.users.assign.okapi , the operation is denied.
3. if the new permission is mutable and operating user permissions and module permissions doesn't contain perms.users.assign.immutable, the operation is denied.
4. if the new permission is immutable and operating user permissions and module permissions doesn't contain perms.users.assign.mutable, the operation is denied.
5. otherwise, the operation is allowed.
The desired permissions perms.users.assign.immutable , perms.users.assign.mutable, perms.users.assign.okapi are not part of perms.all.
TestRail: Results
Attachments
Issue Links
- relates to
-
FOLIO-2582 Privilege escalation tenant admins with permissions.all to okapi.all
-
- Closed
-
-
MODPERMS-159 Set SNAPSHOT version to 6.0.0
-
- Closed
-
-
FOLIO-3321 Update create-tenant-admin role to use new perms.users.assign* permissions
-
- Closed
-
-
MODEXPS-61 User creation fails due to lack of permissions
-
- Closed
-
-
MODINREACH-210 Cannot create user due to lack of permissions
-
- Closed
-
-
MODPERMS-160 Migrate assignment permissions
-
- Closed
-
-
MODPERMS-172 permission assign: lax operating user check
-
- Closed
-
-
MODPERMS-174 modulePermissions not read correctly
-
- Closed
-
-
MODPUBSUB-209 Missing permission for pubsub-user (System)
-
- Closed
-
-
UIU-2542 Create permission sets for the perms.users.assign perms
-
- Draft
-
-
UIU-2549 Include perms.users.assign.mutable/immutable in ui-users.editperms
-
- Closed
-
-
UXPROD-3614 Permissions Management Improvements for Morning Glory
-
- In Refinement
-