Serialize MCP OAuth login and logout#30295
Open
stevenlee-oai wants to merge 7 commits into
Open
Conversation
This was referenced Jun 26, 2026
04aa181 to
96b3707
Compare
0135226 to
fc3ba8b
Compare
96b3707 to
71071e9
Compare
71071e9 to
857c0dd
Compare
fc3ba8b to
5eaa4d4
Compare
This was referenced Jun 27, 2026
…y' into dev/stevenlee/mcp-oauth-independent-4-login-logout-locking # Conflicts: # codex-rs/rmcp-client/src/oauth.rs # codex-rs/rmcp-client/src/oauth/tests/persistor_tests.rs
…y' into dev/stevenlee/mcp-oauth-independent-4-login-logout-locking
…y' into dev/stevenlee/mcp-oauth-independent-4-login-logout-locking
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.
Codex Thread 019edd6d-6f14-74e2-853c-345d1803d4a6
Stack
Review and merge in order. Every layer is independently correct and documents its safe stopping point.
This PR is layer 5.
Why
Refresh serialization is incomplete if OAuth login can overwrite a freshly rotated token or logout can be followed by an in-flight refresh resurrecting credentials. All credential lifecycle mutations for one MCP identity must share the same transaction lock.
What this PR does
Explicit decisions
compute_store_key(server_name, url).Safe stopping point
This completes the correctness stack: aggregate stores, exact-store pinning, refresh, every transport path, login, and logout now use the intended authority and serialization boundaries. Layer 6 is diagnostics only.
Validation
just test -p codex-rmcp-client(114 passed; expected environment skips)just test -p codex-cli