Repository navigation
fix(auth): allow same-origin IPv6 ULA issuers - #1393
Open
mzeng-openai wants to merge 1 commit into
Open
mzeng-openai wants to merge 1 commit into
mzeng-openai wants to merge 1 commit into
Conversation
Contributor
|
@DaleSeo (assignment failed) 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. |
This branch has not been deployed
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.
Motivation and context
A resource configured at
https://[fd00::1]:8443/mcpcan advertisehttps://[fd00::1]:8443as its OAuth issuer. In rmcp 3.7, discovery skips that issuer when it appears inauthorization_servers. If it’s the only entry, login fails before the SDK requests its metadata.Allow a native IPv6 unique-local issuer (
fc00::/7) when its scheme, IP address and effective port match the configured resource. The comparison uses the resource URL even when a different host serves its protected-resource metadata. The SDK’s default HTTP resolver already permits the configured IP literal.How has this been tested?
main, both same-origin regression cases fail. With the patch, all 12 cases pass. The tests check which issuer URL the SDK actually requests, including when the advertised IP, port or scheme differs.auth,clientfeatures.Breaking changes
No API or configuration changes.
Type of change
Checklist
cargo +nightly fmt --all --checkcargo clippy -p rmcp --lib --tests --features auth,client,transport-io -- -D warningsAI assistance
Codex reproduced the issue, wrote the patch and regression tests, ran validation, and drafted this PR description.