Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make grantToken tenant-aware #4475

Merged
merged 4 commits into from Apr 27, 2022
Merged

Make grantToken tenant-aware #4475

merged 4 commits into from Apr 27, 2022

Conversation

lisajian
Copy link
Contributor

@lisajian lisajian commented Apr 25, 2022

Description

Adds multi-tenancy support on grantToken endpoint by pulling tenant ID from refresh token. Changes include:

  • Make refresh token minting / validating stateless by serializing RefreshTokenRecord instead of representing with random string
  • Changing server side logic to check request body's refresh token for tenant ID (note that grantToken is the only endpoint in which the tenant ID cannot be obtained from the request path, query params, or ID token in the request body)
  • Added additional unit tests for grantToken edge cases

Fixes #4414.

Scenarios Tested

npm test passes

Sample Commands

N/A

src/emulator/auth/state.ts Outdated Show resolved Hide resolved
src/emulator/auth/state.ts Outdated Show resolved Hide resolved
@yuchenshi
Copy link
Member

CHANGELOG please

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Invalid Refresh token in emulator with Identity Platform
2 participants