Repository navigation
feat(oidc): list the resources a provider client may get access tokens for - #533
Merged
Merged
Conversation
…' into feat/oidc-client-resources # Conflicts: # src/services/oidcClientRegistry.ts
…urces # Conflicts: # src/services/oidcClientRegistry.ts # tests/unit/services/oidcClientRegistry.spec.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
GET /oidc/clients/:id/resourcesto the service-token/oidc/*routes. Base is #534; merge #534 first.Why
For #509 the OpenID Provider service issues RFC 9068 JWT access tokens for a named API (RFC 8707). The admin side shipped in #526 and
/oidc/signalready checks a token'saudandscopeagainst the client's links, but the edge had no way to learn which resources a client may ask for, with which scopes and lifetime. #534 (#516) also needs the edge to offer the built-in<oidc_issuer>/seamlessresource withnotices:send.What
getOidcClientResources(clientId)returns each resource the client may use: the built-in notices resource when the application hasnoticesEnabled(moved here from feat(oidc): send account notices on a registered application's behalf #534'sgetOidcClientResourceScopes), then each linked resource with the link's scopes narrowed to what the resource declares, andaccessTokenTtlSeconds. A stored resource using the built-in identifier is still ignored.getOidcClientResourceScopes(used by/oidc/sign) is now a map over the same list, so the edge and the signer cannot disagree./oidc/clients/:id.@seamless-auth/types0.34.0-next.2.openapi.jsonandsrc/generated/api.tsregenerated. Minor changeset.No migration. The route is additive, and
OIDC_EDGE_CONTRACT_VERSIONstays 1.Checks
npm run typecheck,npm run lint,npm run format:check,npm run check:changeset-bump: cleannpm run coverage: 2665 passed; lines 99.21, branches 95.69, functions 99.35npm run build: ok<issuer>/seamlessand delivered by email.Part of #509.