Class: SSO::Server::Authentications::Passport
- Inherits:
-
Object
- Object
- SSO::Server::Authentications::Passport
- Includes:
- Logging
- Defined in:
- lib/sso/server/authentications/passport.rb
Instance Method Summary collapse
- #authenticate ⇒ Object
-
#initialize(request) ⇒ Passport
constructor
A new instance of Passport.
Methods included from Logging
#debug, #error, #fatal, #info, #logger, #progname, #warn
Constructor Details
#initialize(request) ⇒ Passport
Returns a new instance of Passport.
7 8 9 |
# File 'lib/sso/server/authentications/passport.rb', line 7 def initialize(request) @request = request end |
Instance Method Details
#authenticate ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/sso/server/authentications/passport.rb', line 11 def authenticate result = authenticate! if result.success? result else # TODO: Prevent Flooding here. debug { "The Passport authentication failed: #{result.code}" } Operations.failure :passport_authentication_failed, object: failure_rack_array end end |