feat(FGAPv2): add GROUPS.reset-password-members scope with alias supp…#42801
Draft
Bagautdino wants to merge 1 commit intokeycloak:mainfrom
Draft
feat(FGAPv2): add GROUPS.reset-password-members scope with alias supp…#42801Bagautdino wants to merge 1 commit intokeycloak:mainfrom
Bagautdino wants to merge 1 commit intokeycloak:mainfrom
Conversation
…ort - Add RESET_PASSWORD_MEMBERS scope to GROUPS resource type - Create alias mapping USERS.RESET_PASSWORD -> GROUPS.RESET_PASSWORD_MEMBERS - Add test for group-based password reset permissions - Leverage existing FGAP v2 alias mechanism for automatic evaluation - Follows deny-overrides and scope-first principles Signed-off-by: Bagautdino <336373@edu.itmo.ru>
Contributor
|
When do you think will this PR be ready? I need this feature for my Keycloak instance. |
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.
Closes: #42597
This PR adds support for
GROUPS.reset-password-membersscope in Fine-Grained Admin Permissions (FGAP) v2, enabling administrators to set up password reset permissions for group members through a minimal, elegant solution leveraging the existing alias mechanism.Related Issues
Motivation
Following the successful introduction of
USERS.reset-passwordscope in PR #41904, administrators need the ability to manage password reset permissions at the group level rather than individual user level. This addresses the group permission requirement mentioned in the original PR discussion and provides a scalable approach to managing password reset policies.What's Changed
AdminPermissionsSchema.java
RESET_PASSWORD_MEMBERS = "reset-password-members"RESET_PASSWORD_MEMBERSto the scopes setUSERS.RESET_PASSWORDtoGROUPS.RESET_PASSWORD_MEMBERSCode Changes
How It Works
The solution leverages FGAP v2's built-in alias mechanism:
reset-password-membersscope automatically becomes available in Admin Console for group policiesGROUPS.reset-password-memberson specific groupsUserPermissionsV2.canResetPassword()is called, the existing alias mechanism automatically:reset-password-memberspoliciesdeny-overridesandscope-firstbehaviorConfiguration
No new configuration options required. The feature works immediately with existing FGAP v2 settings.