Repository navigation
Revocation: carry exp, name what is revocable and where, define errors (#146) - #147
Merged
Merged
Conversation
#146) The revocation request gains exp, the revoked token's own expiration, REQUIRED alongside iss and jti. A recipient MAY discard the entry once exp plus its clock skew has passed. Nothing previously bounded the entry: the section removed the token type, so a recipient could not apply the stated per-type maxima either. Named the three revocable token types and where each is revoked — an agent token only at a PS, a person token and an auth token at the resource — replacing the SHOULD that asked a resource accepting agent tokens to provide a revocation endpoint the agent provider has no way to find. Added the PS-revokes-a-person-token scenario. Replaced the 200/404 response rule with 200 OK once the revocation is recorded, whether or not the recipient holds a record of the token, so a stateless verifier is not answering 404 to every revocation it honors. Defined invalid_request and unsupported_iss, and pointed signature failures at the 401 Signature-Error rules. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01Vibbcv1TAfcACkkbNTkraE
A caller revokes only its own tokens, so iss is redundant with the verified signer. The recipient takes the issuer from the signature and keys the revocation under it, which makes revoking another issuer's token unreachable rather than something a recipient has to refuse. The request is now jti and exp. Dropped the "or from a trusted PS" clause that let one PS revoke another's tokens. Four-party: the AS issued the auth token, so a PS cannot revoke it. The PS revokes the person token at the AS, and the AS cascades to the auth tokens it issued against that person token, at the resource each names in aud. An auth token carries no reference to the person token it came from, so the AS must hold that link; stated the retention both the PS and the AS need, and that it is bounded by the token's own exp — at most an hour. Fixed the PS-to-AS example's Signature-Key: the jwks_uri scheme takes id, dwk, and kid, not a jwks_uri parameter. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01Vibbcv1TAfcACkkbNTkraE
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.
Closes #146.
Request is
jti+expA caller revokes only its own tokens, so
issis redundant with the verified signer. The recipient takes the issuer from the signature and keys the revocation under it — revoking another issuer's token is unreachable, not refused. This also drops the "or from a trusted PS" clause that let one PS revoke another's tokens.expis the revoked token's own expiration. A recipient MAY discard the entry once pastexpplus clock skew, and MAY reject anexpfurther out than the longest lifetime it accepts. Nothing previously bounded the entry: the section had removed the token type, so the stated per-type maxima could not be applied.What is revocable, and where
audand at any AS it was presented to.Four-party chain
The AS issued the auth token, so the PS cannot revoke it. The PS revokes the person token at the AS; the AS cascades to the auth tokens it issued against that person token, calling the revocation endpoint of the resource each names in
aud. The PS also revokes the person token at the resource.An auth token carries no reference to the person token it came from, so nothing on the wire recovers the link — the AS must hold it. Stated the retention this implies for both PS and AS, and that it is bounded by the token's own
exp: at most one hour, not a durable ledger.Response and errors
200 OK, empty body, once the revocation is recorded — whether or not the recipient holds a record of the token. A stateless verifier was previously required to answer404to every revocation it honored. No "not found": a recipient cannot distinguish a token it never saw from one it saw and no longer holds, and an answer that varied would disclose what it holds.invalid_requestjtiorexpunsupported_issserver_errorSignature failures stay at
401withSignature-Error.Drive-by
The PS-to-AS example's
Signature-Keyused ajwks_uri="..."parameter, which thejwks_urischeme does not define — it takesid,dwk, andkid. Fixed, since the revocation rules now depend on the signer's identity being derivable from that header.Resolved by this PR
The malicious-PS flooding question from #146's review largely closes: a PS can no longer revoke tokens it did not issue, so it can only affect its own people, and
expcaps the store at 24 hours of junk. What is left is ordinary per-signer rate limiting.Builds clean with mmark + xml2rfc.
🤖 Generated with Claude Code
https://claude.ai/code/session_01Vibbcv1TAfcACkkbNTkraE