Skip to content

Harden OAuth 2.0 PKCE authentication#1

Merged
niklashof merged 4 commits into
mainfrom
codex/pkce-auth-hardening
Jul 14, 2026
Merged

Harden OAuth 2.0 PKCE authentication#1
niklashof merged 4 commits into
mainfrom
codex/pkce-auth-hardening

Conversation

@niklashof

Copy link
Copy Markdown

Summary

  • replace the legacy password grant with OAuth authorization code + PKCE, based on Implement OAuth 2.0 + PKCE authentication flow dgreif/ring#1750
  • preserve the public refresh-token, 2FA, and token-rotation contracts
  • scope cookies correctly, restrict redirects to Ring origins, validate state and PKCE, and avoid logging auth material
  • keep the unrelated v3 device/location endpoint migration out of this change

Validation

  • npm run test
  • npm run build
  • npm run lint
  • 15 focused auth tests covering 2FA, non-2FA, refresh, plaintext 406, state mismatch, untrusted redirects, both CSRF bootstrap formats, and secret-log regression

Provenance

Auth flow adapted from dgreif#1750 with the open review findings addressed.

@niklashof
niklashof merged commit 8833c23 into main Jul 14, 2026
@niklashof
niklashof deleted the codex/pkce-auth-hardening branch July 14, 2026 16:59
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.

1 participant