joelbutcher / socialstream

OAuth for Laravel, simplified.

Home Page:https://docs.socialstream.dev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Changing email after signing in with a connected account renders account not accessible

mystyq opened this issue · comments

Stack

Jetstream – Livewire

Package Version

^6.0

Laravel Version

11

Livewire Version

No response

react Version

No response

Vue Version

No response

PHP Version

8.3.4

Problem description

After connecting a 3rd party account (by same email) and logging in then changing the email, the account can no longer be accessed by that connected account (because the emails are different)

Expected behavior

Logging in with the connected account should find the associated user (no need to check for the email again)

Steps to reproduce

  1. Create account normally
  2. Connected 3rd party account with same email
  3. Change email in profile view
  4. Log out
  5. Sign in with 3rd party account

Reproduction repository

https://github.com/joelbutcher/socialstream

Relevant log output

No response

Hey @mystyq! We're sorry to hear that you've hit this issue. 💙

However, it looks like you forgot to fill in the reproduction repository URL. Can you edit your original post and then we'll look at your issue?

We need a public GitHub repository which contains a Laravel app with the minimal amount of Socialstream code to reproduce the problem. Please do not link to your actual project, what we need instead is a minimal reproduction in a fresh project without any unnecessary code. This means it doesn't matter if your real project is private / confidential, since we want a link to a separate, isolated reproduction. That would allow us to download it and review your bug much easier, so it can be fixed quicker. Please make sure to include a database seeder with everything we need to set the app up quickly.

This also occurs after connecting an account with a different email. Is the logic for logging a user in from a connected account something that is handled by this library? This seems like a bug to me.

  1. Sign up with registration form (not OAuth flow)
  2. Connect Google account with a different e-mail address.
  3. Sign out of application
  4. Attempt to sign in to application from connected account (Google account)