Skip to content

feat: sign in with ChatGPT and isolate Codex by account - #92

Merged
BunsDev merged 13 commits into
TypeSafeAI:mainfrom
CompleteTech-LLC-AI-Research:chatgpt-signin
Oct 4, 2026
Merged

BunsDev merged 13 commits into
TypeSafeAI:mainfrom
CompleteTech-LLC-AI-Research:chatgpt-signin

Conversation

@CompleteDotTech

@CompleteDotTech CompleteDotTech commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

Adds app-owned Continue with ChatGPT through public dynamic-agent OAuth while preserving Codex CLI authentication. Validates PKCE, state, nonce and signed OIDC identity, stores credentials in protected OS storage, serializes rotating refresh, requires both execution scopes, and supports returning authorization and revocation. Rotated refresh credentials are preserved even when permissions shrink.

Each registration owns a separate Codex app-server. Turn/title leases protect initialization and active consumers; resume handles keep their original identity. Tokens are restricted to the Codex child and redacted from protocol/diagnostic text. Modex makes no inference HTTP calls. The AGENTS.md change permits narrowly scoped authentication networking for maintainer review.

Closes #76. PR #91 is now merged into main. Signed merge 0f6f306 synchronizes this branch with that squash merge and resolves the overlapping Settings, IPC, shared types, health test and status documentation changes, preserving both sign-in flows. Preserves the v0.0.6 release updates from main and #68's terminal recovery behavior.

Validation on final signed head 0f6f306: Apple Silicon build, all 218 desktop unit tests and all 85 Electron e2e tests pass. Required hosted macOS unit + e2e CI passed on this exact head (run 37186542065).

Real macOS 27.0.1 acceptance using Codex CLI 0.153.3 and Electron encrypted storage passed: registration, returning authorization, completed gpt-6-astra turns, real rotating refresh, runtime replacement after renewal, identity-bound resume after account selection changes, separate processes/tokens for two authorized registrations, and scoped server-backed revocation. The surviving registration completed another resumed turn after the other was revoked. Two distinct human account subjects were not established. No credentials or authorization codes were recorded. Claude acceptance used its documented Terminal fallback and confirmed GUI-session authentication; model access remains explicitly unverified for Claude.

No remaining blocking review findings. Contributors cannot merge into TypeSafeAI/modex; a maintainer must land this PR. Recheck required CI after any base/head update.

@CompleteDotTech
CompleteDotTech force-pushed the chatgpt-signin branch 2 times, most recently from d812172 to ffd9bc5 Compare October 3, 2026 22:33

@CompleteDotTech CompleteDotTech left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Review found and fixed two related permission-handling defects in signed commit 87664d7: a successful refresh with reduced scopes must persist its rotating refresh token before denying execution, and plan-authorized account labels must require resource.invoke as well as chatgpt.tokens.use.direct. Regression tests verify denied execution and revocation with the replacement token. Windows build, 25 focused units and 3 Settings e2e tests passed; the Apple Silicon build and full 212 desktop unit tests passed. Required hosted CI is running on the new head. Real registration, reauthorization, subscription-backed turn, refresh/resume, account separation and revocation remain live acceptance gates.

@CompleteDotTech
CompleteDotTech marked this pull request as ready for review October 4, 2026 07:13
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@CompleteDotTech CompleteDotTech left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Reviewed current head 87664d7 against main fc8c699. No new blocking findings. Checked OAuth callback/state/PKCE/nonce and signature validation, protected persistence and locking, rotating refresh including reduced scopes, credential redaction, account process leases, scoped force-stop, bound resume identity, and renderer inability to overwrite bindings. Fresh Apple Silicon auth/account-backend regression run: 20/20 pass. Required macOS CI is green on this exact head. Live registration, returning authorization, real completed Codex turns, rotating renewal/process replacement, separate registration children/tokens, cross-selection resume, and scoped revocation passed. Two registrations were tested; distinct human subjects are not claimed. Nonblocking documentation nit: docs/chatgpt-signin.md still says the PR remains draft; the current acceptance evidence is in the PR description. After either authentication PR lands, recheck the remaining PR against the updated main and require green CI for that resulting head. No merge performed.

@CompleteDotTech CompleteDotTech left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Final review on b8b94cf: integrated PR #91 head 7ec5e55, resolved Settings/IPC/shared-type/status conflicts without dropping either provider flow, and fixed the ambiguous Claude status test selector. Combined Mac build and 218 desktop unit tests passed; required macOS unit + e2e CI now passed on this exact published head (run 37185719311). Live acceptance evidence remains recorded above. No remaining blocking findings. Maintainer landing order: #91 first, then #92; verify required checks after any base/head update. Contributors lack merge permissions; no merge claimed.

@CompleteDotTech CompleteDotTech left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Final review on 5ec85f9: required macOS unit + e2e CI passed on this exact current head. No remaining blocking findings. Documentation reflects completed real acceptance. Preserves the maintainer update to #91 and v0.0.6 main, integrates both sign-in flows, and fixes the combined status selector. Local build, 218 desktop unit tests and all 85 e2e tests pass. Maintainer landing order: #91 first, then #92; verify CI after any subsequent base/head update. Contributors lack merge permission, so neither PR was merged by this session.

@CompleteDotTech CompleteDotTech left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Updated against main 6ade346 after #91 squash merge. Signed merge 0f6f306 preserves the reviewed history and resolves the resulting Settings/IPC/types/health-test/status conflicts. Both sign-in flows remain intact; docs now place Claude on main and keep ChatGPT in flight. Mac build, 218 desktop unit tests and all 85 e2e tests passed. Required macOS CI passed on this exact final head (37186542065), and GitHub reports MERGEABLE. No new blocking findings. Ready for maintainer merge; contributors cannot merge here.

@BunsDev
BunsDev merged commit feaa9df into TypeSafeAI:main Oct 4, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

OpenAI: integrate Sign in with ChatGPT plan usage through Codex app-server

2 participants