8000 Handle Dynamic Scopes correctly in the consent screen · Issue #9224 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content
8000

Handle Dynamic Scopes correctly in the consent screen #9224

Closed

Description

@dgozalo

Description

Given the variable nature of Dynamic Scopes, a special consideration will be required when deciding whether to show a consent screen when a dynamic scope is used in the authentication request.

Some could be configured to always request consent, while others will be passed through if a dynamic scope with the same variable part has been consented before.

We'll also need to decide whether to show these Dynamic Scopes in the same screen as other scopes, or doing so on an individual screen to make it clearer that this scop 8000 e has a variable side that is different from previously consented scopes.

For now, there won't be the possibility of passing a wildcard (*) to let users input the variable part of it.

Discussion

#8532

Motivation

No response

Details

No response

Activity

  1. pedroigor commented on Dec 17, 2021

    @pedroigor
    Contributor

    Does make sense to bypass consent for dynamic scopes? From my POV this type of scope is something that is related with a transaction or interaction that necessarily goes through user consent for approval (thinking about delegation scenarios only).

    If that is true, we should show consent just like a static scope due to the fact that we are probably going to have some metadata associated with dynamic scopes?

  2. dgozalo commented on Dec 20, 2021

    @dgozalo
    ContributorAuthor

    This is indeed a weird one.

    For starters, it would seem like a dynamic scope that has been repeated, (i.e: passing scope:123 twice) would skip the consent screen the second time because, well, a scope with the same variable part has been consented before.

    But on the other hand, it could totally be a completely different "transaction" that needs to be consented every time. I.e: you could send the amount:123 twice, but they would be completely different transactions each time, so consent would be required at all times.

    So it boils down to:

    • Dynamic scopes should always show in the consent screen at least once.
    • A Dynamic Scope can be configured to skip the consent screen if the same scope with the same variable has been consented before.
    • Or it can be configured to always show in the consent screen, regardless of previous consents.

    I hope that makes sense.

  3. pedroigor commented on Dec 20, 2021

    @pedroigor
    Contributor

    Yeah, by "necessarily goes through user consent" I meant that it should consent at least once. But I do see value in also forcing users to consent every time depending on your use case. However, I can not think about a use case where you have a dynamic scope that bypass the consent step completely.

    In terms of UI, I think dynamic scopes should be shown on the same screen because. Why they would need a separate screen? At its core, it is just a scope, right?

  4. dgozalo commented on Dec 20, 2021

    @dgozalo
    ContributorAuthor

    Agreed, we should never let a scope completely skip the consent screen. It should always show at least once.

    About the UI, there were some discussions about having certain, separate screens for dynamic scopes when, for example, a user input would be necessary, to differentiate it from other static scopes.

    But for now, it should be good enough to just show them all in the same screen.

  5. added this to the 17.0.0 milestone on Feb 2, 2022
  6. added a commit that references this issue on Oct 15, 2026
    3528e7b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/featureCategorizes a PR related to a new feature

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0