You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Incomplete fix for CVE-2025-14778: UserManagedPermissionService.delete() still trusts only the first resource of a multi-resource UMA policy #55388
CVE-2025-14778 (#46147) addressed an issue where UMA permission operations only verified ownership against the first resource returned when iterating a multi-resource policy. However, the fix applied a single-resource guard only to update operations in the UMA Protection API (UserManagedPermissionService.update()), leaving deletion (delete()) and retrieval (findById()) unpatched.
When deleting or querying a UMA policy, Keycloak continues to resolve resource ownership by taking the first resource associated with the policy. If a UMA policy is associated with multiple resources owned by different users (for instance, via administrator configuration through the admin API), a user who owns only one of the associated resources can delete or retrieve the entire policy, affecting access control for all other resources governed by that policy.
Version
main branch (commit a29205c778402c02bad1d90b00c390f923d059ac)
Expected behavior
Keycloak should enforce single-resource ownership checks across all UMA permission management operations, including delete() and findById(), rejecting operations on multi-resource policies or ensuring the caller owns all governed resources.
Actual behavior
UserManagedPermissionService.delete() and findById() verify ownership only against the first resource in the policy's resource collection without ensuring the policy is restricted to a single resource. As a result, an owner of one resource can delete or read a shared policy that governs resources belonging to other users.
Acknowledgement
Thank you to adrian_sanrock for reporting this issue. Because reaching a multi-resource UMA policy state requires an administrator to manually configure multiple resources across different owners, this issue is considered a weakness and handled publicly.
This issue was originally tracked in the private repository. Migrated by @abstractj.
Activity
Check ownership of every resource of a user-managed permission
Check ownership of every resource of a user-managed permission
Check ownership of every resource of a user-managed permission
Check ownership of every resource of a user-managed permission
Check ownership of every resource of a user-managed permission
Reject a user-managed permission associated with more than one resource