summaryrefslogtreecommitdiff
path: root/users
diff options
context:
space:
mode:
authorAzul <azul@leap.se>2013-07-16 12:32:43 +0200
committerAzul <azul@leap.se>2013-07-16 12:32:43 +0200
commit6e47ea438cf35c6cad00e65e2817cb57d07db111 (patch)
tree5d7c0450ec483d9e8b0f0f9af85df07cbe81b989 /users
parent9abb7dd66cf44051662bc3b8663e6492dd6d9953 (diff)
use ruby-srp 0.2.0 which has a hex based api
Diffstat (limited to 'users')
-rw-r--r--users/leap_web_users.gemspec2
-rw-r--r--users/lib/warden/strategies/secure_remote_password.rb4
2 files changed, 3 insertions, 3 deletions
diff --git a/users/leap_web_users.gemspec b/users/leap_web_users.gemspec
index 2f4b10c..d33328a 100644
--- a/users/leap_web_users.gemspec
+++ b/users/leap_web_users.gemspec
@@ -17,6 +17,6 @@ Gem::Specification.new do |s|
s.add_dependency "leap_web_core", LeapWeb::VERSION
- s.add_dependency "ruby-srp", "~> 0.1.7"
+ s.add_dependency "ruby-srp", "~> 0.2.0"
s.add_dependency "rails_warden"
end
diff --git a/users/lib/warden/strategies/secure_remote_password.rb b/users/lib/warden/strategies/secure_remote_password.rb
index a97e795..2c681be 100644
--- a/users/lib/warden/strategies/secure_remote_password.rb
+++ b/users/lib/warden/strategies/secure_remote_password.rb
@@ -36,7 +36,7 @@ module Warden
end
def validate
- session[:handshake].authenticate(params['client_auth'].hex)
+ session[:handshake].authenticate(params['client_auth'])
end
def initialize!
@@ -44,7 +44,7 @@ module Warden
client = SRP::Client.new user.username,
:verifier => user.verifier,
:salt => user.salt
- session[:handshake] = SRP::Session.new(client, params['A'].hex)
+ session[:handshake] = SRP::Session.new(client, params['A'])
custom! json_response(session[:handshake])
else
fail! :base => 'invalid_user_pass'