-
Notifications
You must be signed in to change notification settings - Fork 30
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
Not able to login through facebook and google using same email #4
Comments
Yeah. Currently the plugin uses the RPX identifier to authenticate and to create new users in the database. This identifier is unique and links to 1 user on 1 social network. So if you login using 3 different social networks, it will create 3 different users even if the popup remembers the old connection and you use the same email address for each social network... Like written in the README TODO, it should be possible to implement some kind of multiple account mapping. The author of authlogic_rpx wrote some kind of implementation. The first thing we should do is to store the rpx_identifier in a separate table. So one user may have multiple rpx_identifiers. Then, we could write some strategy : for example, like the feature you want to implement : a new connection with a new rpx identifier but using an existing email address could be linked to the existing user... If you work on this, I'll accept your contributions... |
My experience was that if one user [email protected] is logged in through facebook and if John tries to log in through google then another record is not created. Also John is stuck and is not logged in. |
I'm willing to work on patch once I understand the strategy and what needs to be done. |
you need to pay for rpx, and implement single signon |
As said danieljohnmorris, it appears Account Mapping is only available in the Plus account ($10/mo). |
Does that mean when having a Janrain Plus account that feature would work automatically, or are there additional modifications of devise_rpx_connectable needed? |
No you do not need the Janrain Plus, I am currently working on making a fix myself which I can contribute once it's done. But mine will not use has_many :identifiers so that it may be backward compatible, but it can easily be added and I might just do that. |
Thanks for the gem. It works nicely except in one scenario.
In my app email address is key so I have setup such that email must be provided.
I first login through facebook with email [email protected] . So now I have a record in the database for john. I use before_rpx_auto_create hook.
Now if I login through google.com using the same email address [email protected] then even though the rpx box says I am loggin through google.com the signed_in? method of devise returns false.
Any thoughts on this issue.
Thanks
The text was updated successfully, but these errors were encountered: