Skip to content

Add support for organizations feature#338

Merged
jimmyjames merged 2 commits intomasterfrom
orgs-support
Mar 25, 2021
Merged

Add support for organizations feature#338
jimmyjames merged 2 commits intomasterfrom
orgs-support

Conversation

@jimmyjames
Copy link
Copy Markdown
Contributor

@jimmyjames jimmyjames commented Mar 24, 2021

Changes

This PR adds support for the (beta) Organizations and User Invitations features. Changes included:

  • Supports specifying the organization and invitation query parameters when building the Authorization URL
  • Supports verification of the org_id claim in IdTokenVerifier
  • Adds documentation for using the Organizations and User Invitations features

Testing

In addition to unit tests, the change was tested using an application and tenant with the Organizations feature enabled. I verified that with this change it adds the organization and invitation query parameters to the authorization URL to enable login/joining an organization.

Checklist

@jimmyjames jimmyjames added this to the v1-Next milestone Mar 24, 2021
@jimmyjames jimmyjames requested a review from a team as a code owner March 24, 2021 00:33
.build()
.verify(jwt);
}

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.

Should we also add the following two tests:

  • fails when an organization is provided to the IdTokenValidator but no claim was found
  • Doesn't fail when no organization is provided to IdTokenValidator but the token has an org_id claim

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, those are good tests to add, will push a new commit shortly.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Additional tests to cover those scenarios pushed, good catch!

@jimmyjames jimmyjames merged commit 868fcd7 into master Mar 25, 2021
@jimmyjames jimmyjames modified the milestones: v1-Next, 1.28.0 Mar 25, 2021
@jimmyjames jimmyjames deleted the orgs-support branch August 10, 2021 22:23
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.

3 participants