Repository navigation
Conversation
…gle emulator - The token endpoint accepts the JWT bearer grant of service accounts seeded with their public keys, and with sub issues a token acting as a user when domain-wide delegation grants every requested scope. - Signatures, key IDs, lifetimes, scopes and unknown accounts or users are checked with Google's errors, and the other grants are unchanged; covered by tests and documented.
- A service account whose client ID has no domain-wide delegation now gets `unauthorized_client` "Unauthorized client or scope in request.", and one missing a requested scope gets `access_denied`, as Google's JWT error table lists them. - The CLI help describes the JWT bearer grant like the README, docs page, and skill; the other errors are unchanged, with a test for each refusal.
- `access_denied` for a scope the delegation does not grant now answers `400`, RFC 6749's default for token errors, since Google documents no status and no captured response shows one. - `unauthorized_client` for a client without delegation keeps `401`, the status Google returns for it in captured responses; the test asserts both.
- `access_denied` for a scope the delegation does not grant now answers `403`, the status Google returns for it in a captured response. - `unauthorized_client` keeps `401`, and the other errors `400`; the test asserts the new status.
Author
|
Note on the commit "Answer missing delegated scopes with the OAuth default status": its message says no captured response shows a status for |
Contributor
|
@jychp is attempting to deploy a commit to the Vercel Labs Team on Vercel. A member of the Team first needs to authorize it. |
Author
|
Superseded by #406. |
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.
google.service_accounts), and withsubissues a token acting as that user whengoogle.domain_wide_delegationgrants every requested scope.unauthorized_clientfor a client without delegation,access_deniedfor a scope it does not grant) answer as Google's error table lists; the other grants and the permissive default are unchanged, covered byservice-account-delegation.test.tsand documented in the README, docs page, skill, and CLI help.401forunauthorized_client,403with "Requested client not authorized." foraccess_denied) and are otherwise choices listed in the issue (400for the remaining errors, the wrong-audience message, the two legacy audiences, five minutes of clock skew).References:
Fixes #404