Additional Oauth2 providers in phly-expressive-oauth2clientauthentication

phly-expressive-oauth2clientauthentication is a really handy library to authenticate against oauth2 providers. However, it’s currently limited to using only officially maintained providers from the League OAuth2 Client project, namely: Facebook, GitHub, Google, Instagram and LinkedIn.

I would like to be able to use other third party providers or my own custom one with this library so I don’t have to create my own Adapter implementation. My suggestion is that the library continues to recommend officially supported providers but somehow offers the option of registering others.

My use case is that I have a Expressive Oauth2 server using zend-expressive-authentication-oauth2 that I have created a provider for using the conventions for third party providers of league/oauth2-client. And I have a Expressive client app that I want to use phly-expressive-oauth2clientauthentication in.

What do you guys think would be the best way of achieving this?

I would like to see the project continue to be actively maintained and I am happy to contribute if I can.

Why not just contributing to the upstream League OAuth2 Client?

If you mean by putting the provider there, I will do that but it is not really useful yet because the production endpoints in it is not ready.

I thought is was a good idea of using the Authentication Adapter/Session handling in this package for my expressive client instead of reinventing the wheel?

nynka

    May 25

If you mean by putting the provider there, I will do that but it is not really useful yet because the production endpoints in it is not ready.

I don’t understand this specific bit: what does “production endpoints in it is not ready” mean, specifically?

I thought is was a good idea of using the Authentication Adapter/Session handling in this package for my expressive client instead of reinventing the wheel?

By adding yet another client we are re-inventing the client. Why not support upstream development of the League OAuth client, and add custom endpoints there?

Sorry, I am not so good at explaining. :slight_smile: I meant the authorization urls to the oauth server in my third party provider, never mind.

Yes, I guess that is the response I’m looking for as the League OAuth client supports adding custom endpoints, so should the expressive phly-expressive-oauth2clientauthentication package right?

Thank you for your feedback Marco.

ocramius:
By adding yet another client we are re-inventing the client. Why not support upstream development of the League OAuth client, and add custom endpoints there?

Yes, I guess that is the response I’m looking for as the League OAuth client supports adding custom endpoints, so should the expressive phly-expressive-oauth2clientauthentication package right?

If it’s only about configuring League’s component, then indeed :+1:

1 Like

Do I proceed by making a PR?

Yes, please do. Ping my github nick in a comment to the PR once you have, so I can review.

Sure thing! https://github.com/phly/phly-expressive-oauth2clientauthentication/pull/3