Open Closed

Bug: Google SSO login redirects to register page if email address already exists. #2951


User avatar
0
dmeagor created
  • ABP Framework version: v5.2.1
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): yes

When trying to login into an account with Google SSO, when there's an existing email address in the system, it doesn't log in and instead is redirected to the register page.

This is related to this issue: https://support.abp.io/QA/Questions/2852/SSO-requires-the-user-to-register-using-the-login-page

I have opened this ticket on behalf of my developer who still cannot add tickets to this system. More screenshots will follow.

Markdown supported.
Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)

12 Answer(s)
  • User Avatar
    0
    luke created

    In this screenshot you can see that it's using the AbpClaimTypes.Email which is "email", the claim is not found. Login.cshtml.cs OnGetExternalLoginCallbackAsync()

    Then on the register page the email address is prefilled using the standard ClaimTypes.Email object Register.cshtml.cs TrySetEmailAsync()

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    luke created

    After fixing the first issue. I'm now finding it again in the method which is supposed to create a user if there is not one.

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Did you use the AddGoogle?

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    luke created

    I'm using the current out-of-the box implementation, template generated in abp suite 5.2.1. Is there any documentation on how this needs to be changed to make it work?

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    You can change GoogleOptions on this delegate method.

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    luke created

    My point is, that I've generated the project, your login method doesn't work with the default configuration, and there is no documentation on settings this up, what am I missing?

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    luke created

    Also worth noting that I can't sign into this app using Google, same behaviour as I have locally

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    You can create a project, and then share your Google client id and secret and other info, I can try it locally.

    liming.ma@volosoft.com

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    Solution

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    luke created

    That did the trick. Thanks!

    Would work nicely on the ABP support login page too.

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    dmeagor created

    Seems to be working. Can the Google sign on URL be obtained in anyway so that we can pass it to our front end (static cdn deployed) via an api call? It would be nice to have the button on the homepage.

    We could do some hacky iframe thing but I thought there might be a better way.

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    Can the Google sign on URL be obtained in anyway

    Can't understand it very well, Can you explain it in detail?

    Markdown supported.
    Copy, paste, or drag & drop images and files (max 100 MB per file, 100 MB total per post)
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.8.0-preview. Updated on September 28, 2026, 11:44
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.