Skip to content
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

anyone having Authentication failure? #24

Open
Fatman13 opened this issue Oct 28, 2014 · 11 comments
Open

anyone having Authentication failure? #24

Fatman13 opened this issue Oct 28, 2014 · 11 comments

Comments

@Fatman13
Copy link

(linkedin) Callback phase initiated.
(linkedin) Authentication failure! invalid_credentials: OmniAuth::Strategies::OAuth2::CallbackError, OmniAuth::Strategies::OAuth2::CallbackError

/auth/linkedin took me directly to /auth/failure in dev environment. Not seeing linkedin login page.

@ValMilkevich
Copy link

I have it

@yossi-shasho
Copy link

+1
this is the params hash I'm getting in the omniauth failure controller action:
{"message"=>"server_error", "strategy"=>"linkedin"}. no further explanations. any idea anyone?

@ArielAleksandrus
Copy link

I'm getting the same thing. This issue was opened in 2014 and still have no solution?

@johan-smits
Copy link

FYI I switched to the omniauth-linkedin gem and this one works.

@henricazottes
Copy link

I had the following error:

I, [2019-01-11T12:34:11.289315 #7478]  INFO -- omniauth: (linkedin) Request phase initiated.
I, [2019-01-11T12:34:12.237318 #7478]  INFO -- omniauth: (linkedin) Request phase initiated.
I, [2019-01-11T12:34:17.953765 #7478]  INFO -- omniauth: (linkedin) Callback phase initiated.
E, [2019-01-11T12:34:18.598240 #7478] ERROR -- omniauth: (linkedin) Authentication failure! invalid_credentials: OAuth2::Error, : 
{"serviceErrorCode":100,"message":"Not enough permissions to access: GET /me","status":403}

Just changed my gem from gem omniauth-linkedin-oauth2 to gem 'omniauth-linkedin, ran bundle install and it worked! :)

@mmahalwy
Copy link

mmahalwy commented Feb 8, 2019

@henricazottes that is being deprecated no? since it uses v1?

@henricazottes
Copy link

Well, I can see that it was supposed to be deprecated but it still works.
I managed to switch to oauthv2, the problem the op is describing comes from the scope permissions that are different in v2. I went back to omniauth-linkedin-oauth2 and changed

  • r_basicprofile to r_liteprofile
  • in the callback handler, the picture attribute name is not auth.info.image anymore but now auth.info.picture_url

With those changes everything seems to work :)

@mmahalwy
Copy link

@henricazottes I think I will try to squeeze v1 as long as possible!

@mmahalwy
Copy link

mmahalwy commented Mar 8, 2019

@henricazottes found a way to get the profile url? Really sucks if there isn't a way to get that info

@henricazottes
Copy link

Didn't try :/

@GEK62
Copy link

GEK62 commented Jan 7, 2022

I fix it using gem omniauth-linkedin-oauth2 1.0.0 and in devise.rb config.omniauth :linkedin, ENV['LINKEDIN_APP_ID'], ENV['LINKEDIN_APP_SECRET'], scope: 'r_liteprofile,r_emailaddress'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants