8000 Change TokenManager.isValidScope to always consider dynamic scopes by rmartinc · Pull Request #49399 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

Change TokenManager.isValidScope to always consider dynamic scopes - #49399

Merged
pedroigor merged 2 commits into
keycloak:mainfrom
rmartinc:issue-49388
May 29, 2026
Merged

pedroigor merged 2 commits into
keycloak:mainfrom
rmartinc:issue-49388

Conversation

@rmartinc
@rmartinc rmartinc commented May 28, 2026 •
Copy link
Copy Markdown
Contributor

Closes #49388

Checking dynamic scopes I detected that they were not working with CIBA. The reason is the TokenManager.isValidScope is not considering them. This PR changes this to always consider dynamic scopes if enabled. I have revised all calls to the method. Besides I have added the provider for CIBA in the test-framework following the same idea other https resources are integrated. The test uses the CIBA ping to test the two endpoints, I suppose with this the CIBA test classes can also be migrated to the new test-suite.

Closes keycloak#49388

Signed-off-by: rmartinc <rmartinc@redhat.com>
@keycloak-github-bot keycloak-github-bot Bot left a comment
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unreported flaky test detected, please review

@keycloak-github-bot
Copy link
Copy Markdown

Unreported flaky test detected

If the flaky tests below are affected by the changes, please review and update the changes accordingly. Otherwise, a maintainer should report the flaky tests prior to merging the PR.

org.keycloak.testsuite.webauthn.registration.UserVerificationRegisterTest#requiredWrong

Keycloak CI - WebAuthn IT

org.openqa.selenium.NoSuchElementException: 
no such element: Unable to locate element: {"method":"link text","selector":"Register"}
  (Session info: chrome=148.0.7778.167)
For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
Build info: version: '4.28.1', revision: '73f5ad48a2'
...

Report flaky test

@mabartos mabartos left a comment
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rmartinc Nice work! LGTM, just one nitpick that we could improve.

Closes keycloak#49388

Signed-off-by: rmartinc <rmartinc@redhat.com>
@rmartinc
rmartinc requested a review from vaceksimon May 28, 2026 14:23
@rmartinc
Copy link
Copy Markdown
Contributor Author

@vaceksimon I have added you as reviewer, just to take a quick look to the ciba provider. Thanks!

@pedroigor
pedroigor merged commit b883851 into keycloak:main May 29, 2026
87 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Dynamic scopes do not work with CIBA

4 participants

0