Download & Extend

Login/signup to Commons site with Google/Facebook account

Project:Drupal Commons
Version:7.x-3.x-dev
Component:Code
Category:feature request
Priority:major
Assigned:Unassigned
Status:active
Issue tags:architecture

Issue Summary

Per the Commons MVP, let's allow users to login via their Google or Facebook accounts and have an account on the site created in the process.

Available modules/approaches

Facebook:

Google:

General (OAuth):

Comments

#1

Updated summary with the list of available modules.

I prefer uniformed, one to rule them all, general OAuth Connector approach. ;)

#2

I think a general OAuth approach is much better, especially because I consider tight LinkedIn integration a logical extension for Commons.

#3

+1 for general oauth solution. This will facilitate corporate SSO login capabilities. If folks want facebook connect they can add that as an alternative.

#4

FYI, I'm trying to get oauthconnector working with google now. The registration/login is working but username/email are not transferring properly. Hopefully I can report success soon. Folks interested in LinkedIn, Twitter, and Facebook will need to experiment with those separately.

#5

oauthconnector feels like the best idea to me given that it would require supporting just one stack of modules. However, the installed base of oauthconnector is relatively small compared to some of the others. Like Moshe said it seems like this needs a lot of testing and feedback from people who are using it.

#6

Knowing that the planned release of a beta is in July and that folks can easily add in a Facebook Connect module if they choose to, does implementing the generic solution represent a barrier?

I think it is likely that the Facebook Connect has a larger user base because a lot of site builders probably got a higher-ranked search result for it because they typed in "Facebook Connect". My point being that the smaller user base may not be because the oauth module isn't good.

The other slippery slope here is that folks put in Facebook/Google because they're the big ones. What happens when they next want to login to Tumblr or Pinterest or Foursquare ( etc )? Module sprawl seems imminent. It's much easier to add a module to an existing distro than to take it out.

And yes, I am antsy. I've been waiting for Commons for a long time and I'm super excited that it's finally happening! So thank you bunches for working on this!

#7

FWIW: quite interesting sprint / wiki page: Abstracting Social Networking functionality in Drupal, and maybe relevant comment / module: OAuth API?

#8

Status:active» reviewed & tested by the community

We have 5+ general oauth connector recommendations. Marking RTBC since consensus seems to be go general.

#9

#10

I saw that. The article would be way funnier if it wasn't so sad. We've been reading up a lot on SSO solutions lately. The problem is that it appears there is very little standardization to Oauth 2.0 and it is very easy to say you're compliant while still needing some very specific stuff to integrate.

I'm torn on this one. Usually a general solution would be a slam-dunk but Facebook is still using an older draft version of Oauth and several in the tech industry don't think they'll have a reason to upgrade to the full solution.

Google Apps actually offers integration for SAML as well, which is great for enterprise but makes the whole discussion murkier. https://developers.google.com/google-apps/sso/saml_reference_implementation

#11

Hi All,
Has any one looked into how Janrain Engage works as SSO and Social sharing? I was/am using it on my D6 site. Users can create accounts on sign in using many different 3rd parties. I like the idea of it all being in Commons (6x 2.0 update to to 2.5 hid the share button for the Engage module) as to reduce module conflicts in updates, but may solve some early issues in MVP.

BTW, I am not a Drupal genius by any stretch, so sorry if this is wrong post to add. Just trying to help if possible. I am just very excited about 3x.

#12

That would offer a means to a solution. Some thoughts:

1. It would need to be easily turned off because corporate intranets most likely aren't going to allow social logins.
2. This is a paid product. The idea is good but Commons out of the box should not require folks to subscribe for a paid service. Mollom is a paid service too, but it has a free level up to x number of hits.

#13

It took a bit to find, but Janrain Engage (the social login product) is free for up to X users per month: http://janrain.com/products/engage/engage-pricing/

Yet another idea is to use BrowserID - http://drupal.org/project/browserid - which seems great but is not widely supported yet.

#14

Social sharing on Janrain has a disable feature.

#15

Status:reviewed & tested by the community» fixed

Let's go with OauthConnector until we run into specific issues (eg integrating with Facebook) and then re-evaluate at that point.

#16

Title:Login to Commons site with Google/Facebook account» Login/signup to Commons site with Google/Facebook account
Status:fixed» active

Actually, there's no reason to create another issue for this.

Attaching a screenshot from the Commons Interactive prototype that shows what the signup and login pages look like. Note that ideally we could also add Twitter into the list of services.

commons_signup.png

commons_login.png

AttachmentSize
commons_signup.png 48.77 KB
commons_login.png 33.36 KB

#17

Sorry, ezra-g, I'm confused by the statement that there's not a need to create another issue? Not objecting, just not sure what you meant.

I agree on the Oauth Connector path. From looking at the project page, that looks like it will do what is listed in the prototype?

#18

Are there any considerations regarding the PHP cURL requirement for Oauth Connector?

I was surprised during the install, since I consider my dev environment pretty extensive, but could it possibly shy some admins away from Commons in any way? Should it at least be listed as a 3rd party requirement somewhere?

#19

Um, it should be listed, but I would assume that logging in with the Facebook module would require curl as well for a backend page call? Should probably include a readme or a help explaining how they can disable the module if they don't want to use that functionality.

#20

@achton: I was also surprised because I thought that PHP cURL library is must have on LAMP and that I installed it once...but, as VPS will probably be recommended for running Commons, in that case one simple apt-get install php5-curl command will solve this issue.

Nevertheless, definitely worth mentioning in #1660910: Define Commons 7.x-3.x system requirements and #1704202: Commons 3.x documentation.

#21

We can make OAuth optional, so that PHPCurl is recommended, but not required.

#22

Is Acquia Managed Cloud equipped to support this?

#23

@ezra

Making oAuth optional is the way to go

#24

To the extent it's relevant, http://drupal.org/project/commons_profile_social now exists.

#25

Hi, I'm sure it's a little late for new suggestions, but I was wondering if this current solution could easily be replaced? I was looking at HybridAuth Social Sign-on. The maintainer of Ulogin module is now a maintainer of the Hybridauth module, so it should have support.

Hybridauth allows to get and update status on multiple networks as well as login, are there plans to implement something similar with Commons?
~Thanks
Edit: I finally got around to looking at the Oauth Connector that comes with commons and it answered my question. It looks promising.

#26

Status:active» reviewed & tested by the community

It looks like OAuthConnector has been motioned, seconded, and carried.

#27

Facebook fails login to site with the message below.
"Authorization finished
The application has been authorized"

Twitter Connect works and logs you into the site. Both are configured through the connections tab on user profile.

Tested with:

  • centOS
  • FF & IE
  • PHP 5.3.17
  • mySQL 5.5.27-cll
  • Apache/2.2.23

#28

Is there an example module in the plans for this? The only documentation I'm finding is how to sync the profile with Oauth Connector and nothing on publishing content with it. I know that docs will possibly be here one day, but what is the closest document or project that I can look at that might help me understand how to use Oauth connector in more useful ways?
~thanks

Edit: I looked at the code and I see that there is a function available that should be pretty easy to use.
/**
* Endpoint Call.
*
* Use this to post on twitter, get a profile, search in Facebook... and many more.
* You need a $provider, and a access token, that is it... supports both oauth and oauth2.
*/

#29

Status:reviewed & tested by the community» active

Marking as active (until there's a patch/sandbox to review).

#30

[edit] http://drupal.org/project/fb seems worth considering as well.

#31

Tough call, the current solution I believe has much more promise, but it seems like a project that you might more and likely have to take on and put way too much into. Drupal for Facebook(DFF )is a serious Drupal project, and if you want to talk Facebook, that is your premiere project to do it with afaik. Might be overkill to include DFF, but it would go nice with Drupal Specifics if you decide to go such a route. :)

With the Oauth Connector I like the idea to be able to craft my own solutions as needed, but I also would like the idea of an even tighter integration with Facebook. However, the latter doesn't seem as common an idea as the former, so it's your call.

I know that we can count on you for a lot of things, but we can't count on you for everything, so picking whichever project that has the best support helps ease all our troubles.

#32

Well, from looking at the above screenshot you're all set--unless you need more functionality. I just easily added Meetup as a sign up option, so Oauth connector is probably going to be one of your better choices to allow that type of flexibility.

I should mention I couple projects I do like, but they are in sandbox, so not quite ready for prime time.
Social Space, FB Poster

#33

#34

One question: why we don't use http://drupal.org/project/hybridauth for example? I think it really useful. I've used it for several projects. It works with many providers and it's easy to add one more if you need something custom.

#36

Does this mean OAuth will work seamlessly with Commons now?

#37

I haven't had a chance to play with it in awhile, but I was wondering the same thing now that they switched to using the e-mail field for login. I'm not sure what you mean by seamless? I did have some of the social services working, but not like in the prototype screenshot.

#38

I setup the Oauth modules that are included in Commons. There is no documentation on setting them up, so it takes a fair amount of time and trial and error. I haven't figured out how to manually share a users profile pic with commons so they have an avatar at login. Also, I can't figure out how to get the login links to show up on the login or registration form. Anybody had any success or know of documentation?

#39

Hi, Is Oauth setting up the same as setting it up for twitter? There is lots of info about. Or is it different. If so, may be you can volunteer to make the documentation because you already did it!
Greetings, Martijn

#40

When you get to the settings page for oauth connector you have a few options for common systems like Twitter, Facebook, LinkedIn and Google. Selecting one will fill in the values automatically, but it is unclear how to map any fields like the profile picture. Other modules like Janrain engage or Facebook Oauth http://drupal.org/project/fboauth do this out of the box. I still haven't figured it out, and I still have no idea how to get the options to show up on the login or signup page.

#41

Priority:normal» major

Adding the "architecture" tag.

#42

Hmmm.. I'm with Jason on this. I've been fiddling with this for an hour or two now, and I cannot get it to cooperate. If anyone has been able to get this working I'd love some pointers..

Thanks, Johnny

#43

Kickstart was in the same boat.
We are using OAuthConnector, and we haven't had many complaints.
Our screencast is also a good resource: http://www.drupalcommerce.org/blog/4571/kickstart-tip-1-social-logins-ma...

On the other hand, the module is pretty unmaintained.
jsacksick and myself just got commit access and committed the patches we used inside Kickstart, and we can do quick fixes (especially if you provide the patch), but I think that any bigger work would require a rewrite (or bigger cleanup), for which we have no resources. Just a gut feeling.

#44

The oauthconnector module will need love indeed, including figuring out account sync. I'd give this a good week, if not 7-10days of getting it built out, tested on each of the providers (fb, google, linkedin, twitter), syncing changes from the social media provider, and adding social media to users who already exist on the site.

The only thing that seems to work right now is authentication, all other profile data doesn't work, and there is an issue for it on d.o: http://drupal.org/node/1503258 (which from my reasearch shows as needs work, not review, the last comment doesn't make much sense to me)

#45

this is well maintained:

http://drupal.org/project/hybridauth

#46

Thanks, SocialNicheGuru - We'll take a look at that!

#47

As I originally mentioned back in #25 it would probably help tackle the list of issues I mentioned in #35.

#48

I really like hybridauth. +1 on that!

I like that it abstracts all of the social media networks into a php library, even further than what other modules do (which just abstract the social networks into an API for drupal)

The advantage to this is we get every php project using this module to commit changes, which I think will lead to less broken code. It seems that making social media work with login is a practice in the dark arts, mainly because they make API changes and drupal modules don't follow quick enough. My hope is that hybridauth, since its more widely supported outside of drupal, will be quicker to make sure outside changes are reflected in the library.

#49

I'm using it and it seems to work well.

my issue is that I am also using drupal for facebook so I'd like to integrate the two.

#50

Although I haven't had a chance to fully check it out, I've been using the Facebook Autopost. Drupal for Facebook seems to be a solid project, but this one just seemed like it would be easier and lighter to integrate into Commons and possibly with HybridAuth.