Sha256: b5b435a431256c2612c84f48c79905be229055dcd805de4ff9c617dd5f6bcbe2
Contents?: true
Size: 591 Bytes
Versions: 7
Compression:
Stored size: 591 Bytes
Contents
# IMPROVE: redirect to clean the URL from the auth_token. module Janus module Strategies class RemoteAuthenticatable < Base def valid? resource.include?(Janus::Models::RemoteAuthenticatable) && !remote_token.nil? end def authenticate! user = resource.find_for_remote_authentication(remote_token) if user success!(user) else pass end end def remote_token request.params[resource.remote_authentication_key] end def auth_method :set_user end end end end
Version data entries
7 entries across 7 versions & 1 rubygems