Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@muhammedogz
Copy link
Contributor

Closes #45428

Description

Fixed wrong redirect for permissions accessed via resource details in the Admin UI authorization panel.

When clicking on a permission from the Resources tab, the navigation was always treating it as a "resource" type
permission, even for scope-based permissions.

Changes

  1. js/libs/keycloak-admin-client/src/resources/clients.ts

    • Fixed listPermissionsByResource return type from ResourceServerRepresentation[] to
      PolicyRepresentation[] to match actual API response
  2. js/apps/admin-ui/src/clients/authorization/DetailCell.tsx

    • Changed hardcoded permissionType: "resource" to permissionType: permission.type!
    • Updated type imports to use PolicyRepresentation
  3. js/apps/admin-ui/src/clients/authorization/ResourceDetails.tsx

    • Updated type imports to use PolicyRepresentation
  4. js/apps/admin-ui/src/clients/authorization/Resources.tsx

    • Updated type imports to use PolicyRepresentation

Fix Result

kc-resource-navigate-fix.webm

   redirect in resource details

   Closes keycloak#45428

Signed-off-by: Muhammed Oguz <[email protected]>
@ahus1 ahus1 merged commit 051fcab into keycloak:main Jan 21, 2026
60 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Admin UI: Wrong redirect for permissions accessed via resource details

3 participants