reu / omniauth-steam

Steam authentication strategy for OmniAuth
93 stars 38 forks source link

invalid credentials #8

Closed dandybreath closed 11 years ago

dandybreath commented 11 years ago

i am using rails 4 web apps, and after login, auth callback give error message Omniauth:Error 'invalid credentials'

reu commented 11 years ago

Can you provide an example application that reproduces this error?

dandybreath commented 11 years ago

i'm using free .co.vu domain to test and get steam api key my omniauth.rb :

require 'openid/store/filesystem'
require "omniauth/strategies/steam"

Rails.application.config.middleware.use OmniAuth::Builder do
  provider :steam, 'STEAM_KEY', :storage => OpenID::Store::Filesystem.new("/tmp")
  OmniAuth.config.on_failure = Proc.new { |env|
    OmniAuth::FailureEndpoint.new(env).redirect_to_failure
  }
end

gemfile : gem 'omniauth-openid' gem 'omniauth-steam'

reu commented 11 years ago

Looks like this is intermittent. I am trying to reproduce your issue here, but as far as I can see, Steam is in some trouble today as everything is VERY slow (it is even refusing the connection some times).

I am gonna keep a look at this though.

dandybreath commented 11 years ago

i am also trying with openid

use OmniAuth::Builder do
  provider :open_id, :name => 'steam', :identifier => 'http://www.steamcommunity.com/openid'
end

and the same result given. maybe omniauth has problem with rails4? :\

i am also running bot with c# mono and its work fine, so i think its not steam connection

you can check my site : http://dota2indo.co.vu/

reu commented 11 years ago

I couldn't reproduce your issue... could you please try the rails example (it is in the examples folder of the repository), and tell me what you get?

I just successfully logged in a few times with two different users and (besides the slowness) using the example application...

reu commented 11 years ago

It will ask you for a API key on the server startup, you can use mine for now (it is mapped to localhost): C7B23511DE49353029EAEE4648C0B7F2

dandybreath commented 11 years ago

hi, thanks for your reply i can logon with your example apps on my local machine, but it didnt work with rails on my vps.

here's my rails code, https://www.dropbox.com/s/d79xyzjvd40ipxr/d2i.zip

edit: ah didnt see u're adding rails example, i'll try your rails example

dandybreath commented 11 years ago

your example was success on my local machine, but unfortunately not on my vps here's the log file : http://tny.cz/28326fc2

also use ip-address to login but it's return still invalid_credentials

http://s18.postimg.org/y6h1pi4mx/error.png

reu commented 11 years ago

I think that Steam is with problems today. Let's see if you still get errors tomorrow.

I just got the example up and running on Heroku and it is working fine: http://omniauth-steam-example.herokuapp.com/

dandybreath commented 11 years ago

is this problem related to this https://github.com/mkdynamic/omniauth-facebook/issues/107 ?

dandybreath commented 11 years ago

i see http://stackoverflow.com/questions/8336455/rails3-omniauth-google-authentication-on-returns-user-identity has problem with his vps too, but i didn't know how to monkey patching this omniauth-steam

reu commented 11 years ago

@dandybreath are you still experiencing this error?

I read the two problems, and as far as I can see, there is nothing we can do to in the omniauth-steam to fix that.

BTW, my online demo at http://omniauth-steam-example.herokuapp.com/ still runs flawless on rails 4, which makes everything yet more obscure.

dandybreath commented 11 years ago

yes, now i know that it's not omniauth-steam issue. it's either my vps or steam service, the error message was not clear though

cbrunsdon commented 10 years ago

If you check out https://github.com/openid/ruby-openid/pull/54, the issue you are having might be related to that.