Skip to content

fix(auth): accept ID-JAGs without a resource claim - #1406

Merged
gocamille merged 3 commits into
modelcontextprotocol:mainfrom
daviddanialy:ema-optional-resource-claim
Oct 30, 2026
Merged

gocamille merged 3 commits into
modelcontextprotocol:mainfrom
daviddanialy:ema-optional-resource-claim

Conversation

@daviddanialy

Copy link
Copy Markdown
Contributor

Fixes #1404

The ID-JAG validation in transport/auth/enterprise.rs required a resource claim, but the claim is optional in draft-ietf-oauth-identity-assertion-authz-grant, and the MCP EMA extension only constrains it when present. Okta Cross App Access omits it, so rmcp clients couldn't use Okta-issued ID-JAGs.

  • IdJagClaims.resource is now Option<Resource>. An omitted claim is accepted; an explicit null is still rejected.
  • When present, the claim (and the token-exchange response's resource) must still exactly match the requested resource. Without it, the ID-JAG is bound to the resource AS by aud.
  • Tests cover the omitted, matching, mismatched and null cases, and an end-to-end redemption without the claim.

@daviddanialy
daviddanialy requested a review from a team as a code owner October 28, 2026 21:36
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-30T16:45:21.999375Z 9720ea8 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions github-actions Bot added T-test Testing related changes T-core Core library changes T-transport Transport layer changes labels Oct 28, 2026
@github-actions
github-actions Bot requested a review from gocamille October 28, 2026 21:37
@github-actions

Copy link
Copy Markdown
Contributor

@gocamille is on triage rotation this week and is the reviewer for this one.

Labels come from the PR labeler. Please review the change.

Automated triage. Labels are a first pass and the assigned maintainer has the final say.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 51e8177fc5

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@github-actions github-actions Bot added the T-documentation Documentation improvements label Oct 28, 2026
Comment thread docs/OAUTH_SUPPORT.md Resolved
gocamille
gocamille previously approved these changes Oct 30, 2026

@gocamille gocamille left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This looks good to me, thanks @daviddanialy! I checked the two new tests against main and they both fail there for the right reason. I left a few small optional ones inline but none of them are blocking 👍

@daviddanialy
daviddanialy dismissed stale reviews from gocamille via 9720ea8 October 30, 2026 16:42
@daviddanialy

Copy link
Copy Markdown
Contributor Author

@gocamille Pushed the two optional suggestions, which dismissed the approval. Mind re-approving when you get a chance?

@daviddanialy

Copy link
Copy Markdown
Contributor Author

@gocamille Approved and green, ready to merge whenever you get a chance

@gocamille
gocamille merged commit c164688 into modelcontextprotocol:main Oct 30, 2026
44 of 46 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T-core Core library changes T-documentation Documentation improvements T-test Testing related changes T-transport Transport layer changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enterprise-managed auth: ID-JAG resource claim should be optional

2 participants