Uploaded image for project: 'OpenAM'
  1. OpenAM
  2. OPENAM-14643

OIDC Dynamic Client Registration registration_client_uri does not work for root realm

    Details

    • Target Version/s:
    • Sprint:
      AM Sustaining Sprint 61, AM Sustaining Sprint 62
    • Story Points:
      2
    • Needs backport:
      No
    • Verified Version/s:
    • Needs QA verification:
      Yes
    • Functional tests:
      No
    • Are the reproduction steps defined?:
      Yes and I used the same an in the description

      Description

      Bug description

      Creating a dynamic client registration and checking the registration_client_uri shows that it has <url>/oauth2/oauth2/register?client_id=<value> and this does not work. There is no issues with subrealm (it is accessible) but yet not so right and is <url>/oauth2/realms/root/realms/subrealm/oauth2/register?client_id=<value>

       This does not affect 6.5.x.

      How to reproduce the issue

      Details steps outlining how to recreate the issue (remove this text)

      1. Install OAuth2/OIDC provide with dynamic client registration
      2. Create a new Client registration
      3. Check the generated client's registration_client_uri
      Expected behaviour
      The registration_client_uri is correct on the root realm and subrealm
      
      Current behaviour
      The root realm's registration_client_uri is wrong and cannot be access. Although the subrealm registration_client_uri works it has a redundant /oauth2.
      

      Work around

      Do not work on / realm

      Code analysis

      DynamicClientRegistraionService.java
      Find the "/oauth2/register?client_id=" and remove "/oauth2"
      

      Test suggest this will work for both root realm/subrealm. This problem is seen after the Restlet removal.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                chee-weng.chea C-Weng C
                Reporter:
                chee-weng.chea C-Weng C
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: