SCIM: Groups endpoint members operations do not enforce isAdminUser c…#50961
Merged
Conversation
…heck Closes keycloak#50473 Signed-off-by: Martin Kanis <mkanis@ibm.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Prevents SCIM /Groups PATCH operations from modifying memberships of admin-role-bearing users, resolving #50473.
Changes:
- Rejects admin-user membership additions and removals with HTTP 403.
- Adds an admin-user test fixture and integration coverage for both operations.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
scim/model/.../GroupCoreModelSchema.java |
Adds the admin-user protection check. |
scim/tests/.../AdminGroupProtectionRealmConfig.java |
Defines an admin-role-bearing test user. |
scim/tests/.../AdminGroupProtectionTest.java |
Tests blocked membership additions and removals. |
sguilhen
reviewed
Jul 16, 2026
sguilhen
left a comment
Contributor
There was a problem hiding this comment.
Thanks @martin-kanis , the PR looks good to me!
sguilhen
approved these changes
Jul 16, 2026
ahus1
approved these changes
Jul 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…heck
Closes #50473