Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

"permission_unknown" bug or failure to understand docs #91

Closed
wulffeld opened this Issue Dec 8, 2011 · 3 comments

Comments

Projects
None yet
2 participants

wulffeld commented Dec 8, 2011

I've struggled for countless hours now trying to figure out how to get the pin (oauth_verifier) into the mix without user interaction. I thought it was easy enough just getting the oauth_verifier from params but I keep getting permission_unkown in this line:

https://github.com/wulffeld/test-linkedin-devise-omniauth/blob/master/app/controllers/connections_controller.rb#L7

If someone could point me in the right direction I'd be grateful. I have created a minimal project that uses devise, omniauth-linkedin and obviously this gem here: https://github.com/wulffeld/test-linkedin-devise-omniauth

It's mongodb based so if you have mongodb running it should work more or less out of the box - just add a config.yml file in config with the key/secret:

development:
  linkedin_key: MYKEY
  linkedin_secret: MYSECRET

On the home page click 'Sign in' then 'Sign in with Linkedin' to auth with LinkedIn.

After that just hit the /connections url and the error should appear.

If i do the example (at https://github.com/pengwynn/linkedin) where I manually get the pin it works just fine.

Collaborator

ryanatwork commented Dec 8, 2011

Maybe this project can help you? I'm using the Gem in this Rails project and does not ask for a pin.

https://github.com/codeforamerica/FellowsExchange

I think the code that will help is in this sessions controller - https://github.com/codeforamerica/FellowsExchange/blob/master/app/controllers/sessions_controller.rb

Collaborator

ryanatwork commented Dec 8, 2011

Also this app might help - https://github.com/ryanatwork/sign-in-with-linkedin however it doesn't look like the demo site is functioning correctly.

wulffeld commented Dec 8, 2011

Ahhh so I have to use authorize_from_access. Sigh, many hours wasted there :) I had actually tried using that but with the wrong token/secret and then everything just spiralled out of control :)

Thanks a lot, Ryan! Lifesaver.

@wulffeld wulffeld closed this Dec 8, 2011

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment