server
server copied to clipboard
BUG: Space Admin has admin privilege on Platform level
Describe the bug A clear and concise description of what the bug is.
To Reproduce Steps to reproduce the behavior:
- Go to https://acc-alkem.io/graphql
- Make sure you are authenticated with Space admin and not GA or GSA
- Run the following query
query {
platform {
authorization {
myPrivileges
}
}
}
- User get "admin" privilege on platform level
Expected behavior Space admin doesn't have "admin" privilege on platform level.
Additional context The server doesn't allow the user to reset policies of other spaces, change space / account platform settings or create innovations packs.
@Comoque1 good catch - this is I think a legacy assignment that was done to allow the space admin to access the admin section of the site. It can likely go, once the PR related to the path changes are done: https://github.com/alkem-io/client-web/pull/6159
@me-andre how is it working with settings on a user / org? I can imagine there is the same issue re paths there...
Verified locally, no longer the case. With a user that is SPACE_ADMIN on one space only, and no PLATFORM roles, I have:
query {
platform {
authorization {
myPrivileges
}
}
}
{
"data": {
"platform": {
"authorization": {
"myPrivileges": [
"READ_USERS",
"CREATE_ORGANIZATION",
"ACCESS_INTERACTIVE_GUIDANCE"
]
}
}
}
}