LinkedIn OAuth2 Plugin

Were they some changes recently on the plugin or the Discourse or even on the Linkedin API? Because I can’t seem to login anymore to my forum with LinkedIn. It shows the “Sorry, there was an error authorizing your account. Perhaps you did not approve authorization?”. I use http and everything seemed to work fine until a friend told me that my LinkedIn sign-up doesn’t work anymore. My log:

(linkedin) Authentication failure! invalid_credentials: OAuth2::Error, invalid_request: missing required parameters, includes an invalid parameter value, parameter more than once. : Unable to retrieve access token : appId or redirect uri does not match authorization code or authorization code expired
{“error_description”:“missing required parameters, includes an invalid parameter value, parameter more than once. : Unable to retrieve access token : appId or redirect uri does not match authorization code or authorization code expired”,“error”:“invalid_request”}

Yes, everything is up-to-date! :slight_smile:

Now I got this message:

(linkedin) Authentication failure! access_denied: OmniAuth::Strategies::OAuth2::CallbackError, access_denied | the user denied your request

If noone else is experiencing this how can I resolve it or where to look?

I am getting this error on a new install

(linkedin) Authentication failure! invalid_credentials: OAuth2::Error, invalid_request: missing required parameters, includes an invalid parameter value, parameter more than once. : Unable to retrieve access token : appId or redirect uri does not match authorization code or authorization code expired
{“error_description”:“missing required parameters, includes an invalid parameter value, parameter more than once. : Unable to retrieve access token : appId or redirect uri does not match authorization code or authorization code expired”,“error”:“invalid_request”}

Has anyone got any ideas?

I followed all the steps, I also authorized the right redirect url.

But I got the same error.

I am redirected to this url :

https://[MY_WEBSITE]/auth/failure?message=invalid_credentials&origin=[MY_WEBSITE]&strategy=linkedin#!

I’m having the same version on the hosted version.

After logging in to LinkedIn successfully I receive this message,

Sorry, there was an error authorizing your account. Perhaps you did not approve authorization?

URL is https://SITE.com/auth/failure?message=invalid_credentials&origin=https%3A%2F%SITE.com%2F&strategy=linkedin#!

I managed to fix this connecting to the container and then following the posts here

I realise this is a work around but is ok until the issues are fixed upstream.

4 Likes

Just to let this thread know the latest version of the plugin seems to work ok.

3 Likes

Any word on if this is fully working with 1.9?

It is official so it should work

2 Likes

It seems to work with the latest build: [v2.0.0.beta4 +77]

Just installed it.

Thanks for this plugin :slight_smile:

1 Like

Thanks for the plugin. I installed it on the latest version of discourse (2.3.0.beta9). I set it up and configured it according to the instructions. However, upon logging in, authenticating successfully, and being redirected back to Discourse, I am getting this error:

(linkedin) Authentication failure! invalid_credentials: OAuth2::Error, : 
{
  "errorCode": 0,
  "message": "This resource is no longer available under v1 APIs",
  "requestId": "015LRC6C8X",
  "status": 410,
  "timestamp": 1558803860356
}

Is this plugin updated and working with the latest LinkedIn v2 API?

1 Like

No, it doesn’t work with the v2 endpoint currently.

We are using the omniauth-linkedin gem 0.2.5 and we need to upgrade to 1.0.0 to get v2 compatibility.

6 Likes

Hi @Kurt

I’ve just updated the plugin to use LinkedIn v2 API, please update to latest and let me know if the problem persists.

5 Likes

I updated the plugin and it works great. I was able to successfully login using LinkedIn v2 API. Thanks for the swift action on this!

3 Likes