Skip to content

Update/oauth3 cvm url#3

Merged
2xburnt merged 2 commits intomainfrom
update/oauth3-cvm-url
Mar 5, 2026
Merged

Update/oauth3 cvm url#3
2xburnt merged 2 commits intomainfrom
update/oauth3-cvm-url

Conversation

@2xburnt
Copy link
Contributor

@2xburnt 2xburnt commented Mar 4, 2026

This pull request refactors the OAuth3 authentication flow to improve security and simplify session management. The main changes remove token handling from the client and rely solely on the CVM's session cookie (sid) for authentication, streamlining the OAuth3 integration. Additionally, sharing and social features now use the current site origin dynamically instead of hardcoding URLs.

OAuth3 Authentication Flow Refactor:

  • Removed client-side handling and storage of OAuth3 tokens; authentication now uses the CVM's sid session cookie set via the /oauth3 reverse proxy. This affects the callback, login, and verify endpoints (src/app/api/oauth3/callback/route.ts, src/app/api/oauth3/login/route.ts, src/app/api/oauth3/verify/route.ts). [1] [2] [3] [4] [5] [6]
  • Updated .env.example and .env.production to clarify server-only OAuth3 settings and removed unused client-side OAuth3 base URL variables. [1] [2]

Dynamic Site Origin for Sharing:

Authentication Redirect Improvements:

  • Updated the authentication redirect callback URL in the root layout to consistently use /verify after OAuth3 login.

@github-actions
Copy link

github-actions bot commented Mar 4, 2026

🚀 Preview Deployment

Version ID: 43660797-f87a-478d-8423-81c655d0c5d4
Preview URL: https://43660797-redacted.burnt.workers.dev
To deploy: npx wrangler versions deploy 43660797-f87a-478d-8423-81c655d0c5d4 --percentage 100

@2xburnt 2xburnt merged commit 59a812b into main Mar 5, 2026
1 check passed
@2xburnt 2xburnt deleted the update/oauth3-cvm-url branch March 5, 2026 01:35
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