Repository navigation
Conversation
- Exclude realm management client roles and their derived audiences from access tokens and introspection responses - Preserve realm roles, application client roles, and their audiences - Package the mapper in the Keycloak image, run its tests in CI, and document the upgrade order Relates to openremote/core#3566
4 tasks
- Adopt the Keycloak 26.8.2 server BOM for both providers and align the registration listener from 26.6.4 to 26.8.2 (https://github.com/keycloak/keycloak/releases/tag/26.8.2) - Move the token filter’s JUnit and Mockito dependencies into the version catalog - Remove unused catalog entries left by the fixed-issuer provider - Centralize Maven Central in settings.gradle and disallow project-level repositories
- Discover subprojects from build.gradle files and honor .buildignore - Exclude generated and dependency directories from discovery - Run all Gradle tests in a dedicated CI step before packaging
- Run the specifications with Spock 2.5 and Groovy 6.0.1 on JUnit Platform - Replace JUnit Jupiter and Mockito with Spock assertions and built-in mocks - Preserve all five test cases, including exclusions for other clients and realms
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.
Description
Master access tokens grow as realms are added because the master admin role inherits each realm’s Keycloak management client roles. With enough realms, those roles and their audiences can make tokens too large for proxy requests.
This PR packages a protocol mapper that filters realm-management client roles and their derived audiences from access tokens and introspection responses for the
openremoteclient in themasterrealm. Realm roles, application client roles, and their audiences are preserved. Other clients and realms are unaffected.Build changes
./gradlew testin a dedicated CI step before packaging, covering all discovered subprojectssettings.gradleand disallow project-level repositoriesbuild.gradlefiles, honor.buildignore, and exclude dependency and build-output directoriesRollout
Upgrade the Keycloak image before starting the Manager version that enables the mapper. The Manager attaches it when Keycloak advertises it. If the mapper is unavailable, the Manager leaves the client configuration alone and checks again on its next startup. Users receive smaller tokens on their next login or token refresh.
Validation
./gradlew testpassed locally and both provider JARs built.buildignorebehave as expectedCompanion Manager PR openremote/core#3603
Relates to openremote/core#3566