Description: This is a Drupal module that allows users to login to other sites through your site, using OAuth2.
Sandbox: https://drupal.org/sandbox/dashohoxha/2164123
Git: git clone --branch 7.x-1.x dashohoxha@git.drupal.org:sandbox/dashohoxha/2164123.git oauth2_loginprovider

Comments

PA robot’s picture

Multiple Applications
It appears that there have been multiple project applications opened under your username:

Project 1: https://drupal.org/node/2164201

Project 2: https://drupal.org/node/2138549

As successful completion of the project application process results in the applicant being granted the 'Create Full Projects' permission, there is no need to take multiple applications through the process. Once the first application has been successfully approved, then the applicant can promote other projects without review. Because of this, posting multiple applications is not necessary, and results in additional workload for reviewers ... which in turn results in longer wait times for everyone in the queue. With this in mind, your secondary applications have been marked as 'closed(duplicate)', with only one application left open (chosen at random).

If you prefer that we proceed through this review process with a different application than the one which was left open, then feel free to close the 'open' application as a duplicate, and re-open one of the project applications which had been closed.

I'm a robot and this is an automated message from Project Applications Scraper.

PA robot’s picture

Status: Needs review » Needs work

There are some errors reported by automated review tools, did you already check them? See http://pareview.sh/pareview/httpgitdrupalorgsandboxdashohoxha2164123git

We are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)

Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).

I'm a robot and this is an automated message from Project Applications Scraper.

dashohoxha’s picture

Status: Needs work » Needs review

Thanks PAReview.sh. Now it is clean.

bojanz’s picture

I think #2138549: [D7] OAuth2 Client should be used for the project application instead, you don't want to use pure oauth2 as a login provider, you want to layer openid connect on top instead (since it's more secure and has the needed features).

dashohoxha’s picture

Thanks for the feedback bojanz. If I could, I would use both of them for the application. This one has the advantage that it is very simple. It is just a copy of oauthloginprovider, but for oauth2 (using oauth2_server).

I am using it, so I don't see why it should not be used. I am also preparing some other modules on the client side that will be used to connect to this module and to login through it. On the other hand, I have no idea about how to use openid connect (that you mentioned).

bojanz’s picture

Well, you always choose one module for the application, that's why I suggested the more logical one. But in the end it's your choice.

dashohoxha’s picture

xqus’s picture

Manual review of your code:

License
Please remove the LICENSE.txt file. Drupal will add the appropriate version automatically during packaging so your repository should not include it.

In oauth2_loginprovider_services_resources(), the help text should pass trough t().

dashohoxha’s picture

xqus, thanks for reviewing and for catching these issues. I just fixed them.

dashohoxha’s picture

The module OAuth2 Login (https://drupal.org/sandbox/dashohoxha/2167191) can be used on the client side for testing OAuth2 Login Provider (which is on the server side).

dashohoxha’s picture

All these three modules: oauth2_client, oauth2_loginprovider and oauth2_login, are related to each-other and part of a working solution, along with a few patches to other modules:

If there is something that you don't like about this module (oauth2_loginprovider), let us improve it. Would you like to make it more compatible to the standards (for example OpenID standard)? Great, I have never been against using standards. I can also make you a maintainer of the project. I tried to do the best that I could, but maybe you know better than me. Let's try to improve it.

However, as we improve it, let's try to reflect the changes to the other parts of the solution, so that the package as a whole is not broken and it is still working.

On the other hand, if we find that it is difficult to fit the OpenID Connect standard to this solution, then most probably we should keep both of them as alternative solutions. I agree with collaboration over competition, but this does not mean that we should kill diversity. If one solution makes more sense in one situation and another solution makes more sense in another situation, then both of them should be kept and let everybody choose which one is more suitable for his case.

blainelang’s picture

I was looking for a clean working OAuth 2.0 Drupal client that I could use for a project and the oauth2_client that @dashohoxha wrote was just what I needed. It's clean and worked really well. I was able to easily extend it with my own client definition.

I certainly looked at all the other existing OAuth 2 projects and they are just are more complex or written to be OAuth servers first, or different use-cases.

This module came with a clean example and was easy to re-purpose.

Thanks Dashamir for your contribution.

blainelang’s picture

Status: Needs review » Reviewed & tested by the community

I've reviewed this project and it's needed.

dashohoxha’s picture

blainelang, thanks for the review and for the support.

I have just added a simpletest file for oauth2_loginprovider:
http://drupalcode.org/sandbox/dashohoxha/2164123.git/blob/HEAD:/tests/oa...

It can help to easily test this module, and also to show how it can be used. To test oauth2_loginprovider in a normal Drupal site, the module oauth2_login is needed. I am planing to write a short howto in the near future about how to do this.

dashohoxha’s picture

I think that the setUp() of the test file shows clearly the configurations that need to be done in order to make oauth2_loginprovider and oauth2_login work together:
http://drupalcode.org/sandbox/dashohoxha/2167191.git/blob/refs/heads/7.x...

The most tricky part is installing the correct versions of the required modules and libraries, since some of the patches have not been applied upstream yet. The make files of these modules can help a lot about this.

Do you think that a howto is still needed?

mitchell’s picture

Status: Reviewed & tested by the community » Fixed

Thanks for your contribution, dashohoxha!

I updated your account so you can promote this to a full project and also create new projects as either a sandbox or a "full" project.

Here are some recommended readings to help with excellent maintainership:

You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and stay involved!

Thanks to the helpful reviewers as well.

dashohoxha’s picture

Status: Fixed » Closed (fixed)

Thanks.
I just made the first release: 7.x-1.0