Prevent Codex from invalidating active user auth while running production QA
What happened
During a production authenticated-API QA run, Codex used a Supabase service-role flow:
admin.generateLink({ type: "magiclink", email })verifyOtp(...)
That minted a session for a real internal account. This can replace or invalidate the account's active passwordless login path. The user had just reset their state to recover from an earlier interruption and was forced to do it again.
User impact
A production QA action changed live authentication state without an explicit warning or confirmation. The user lost continuity and had to repeat a reset.
Expected guardrail
Treat passwordless sign-in flows, magic links, OTPs, sessions, and similar authentication state as externally visible mutable state.
Before an agent mints or verifies a magic link for an existing account, Codex should require explicit confirmation and offer a safer default:
- use a dedicated isolated QA identity,
- reuse a user-provided short-lived bearer token, or
- perform only unauthenticated/read-only validation.
The agent should not assume that service-role access makes this safe to do against an account that may be actively in use.
Notes
No secrets or credential values were printed. The issue is about agent-side action authorization and protecting the user's active session during live QA.
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗