Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(passport): Use Rollup creds for OAuth logins when custom domain configured #2336

Closed
betimshahini opened this issue May 29, 2023 · 1 comment · Fixed by #2364
Closed
Assignees
Labels
enhancement Indicates new feature requests

Comments

@betimshahini
Copy link
Contributor

We want to enable devs to leverage out OAuth client creds for the OAuth providers we support even in scenarios where they use their own custom domain.

To enable this, we'd need to leverage passport.rollup.id as a redirect-based proxy so that the session cookie is issued for the custom domain, while leveraging all the redirect logic that's currently in place for rollup.id.

High level this would work as follows:

  • OAuth login options in custom domain Passport would point to /connect/(provider) routes in Passport under rollup.id
  • Passport would set a property in the authenticator cookie with the custom domain and proceed with upstream OAuth authentication.
  • On callback, introspect the cookie and retrieve the custom domain
  • Redirect to custom domain Passport (route /connect/(provider)/callback) with query params from the callback to Passport under rollup.id
@betimshahini betimshahini added the enhancement Indicates new feature requests label May 29, 2023
@betimshahini betimshahini added this to the v1 - white label milestone May 29, 2023
@betimshahini betimshahini modified the milestones: v1 - white label, beta May 29, 2023
@szkl
Copy link
Contributor

szkl commented May 30, 2023

Passport would set a property in the authenticator cookie with the custom domain

The referer could be used to read the custom domain. Though, not sure how to validate it for custom domains only.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Indicates new feature requests
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants