Class: Osso::SamlHandler
- Inherits:
-
Object
- Object
- Osso::SamlHandler
- Defined in:
- lib/osso/lib/saml_handler.rb
Instance Attribute Summary collapse
-
#attributes ⇒ Object
Returns the value of attribute attributes.
-
#provider ⇒ Object
Returns the value of attribute provider.
-
#session ⇒ Object
Returns the value of attribute session.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(auth_hash:, provider_id:, session:) ⇒ SamlHandler
constructor
A new instance of SamlHandler.
- #perform ⇒ Object
Constructor Details
#initialize(auth_hash:, provider_id:, session:) ⇒ SamlHandler
Returns a new instance of SamlHandler.
11 12 13 14 15 |
# File 'lib/osso/lib/saml_handler.rb', line 11 def initialize(auth_hash:, provider_id:, session:) find_provider(provider_id) @attributes = auth_hash&.extra&.response_object&.attributes @session = session end |
Instance Attribute Details
#attributes ⇒ Object
Returns the value of attribute attributes.
5 6 7 |
# File 'lib/osso/lib/saml_handler.rb', line 5 def attributes @attributes end |
#provider ⇒ Object
Returns the value of attribute provider.
5 6 7 |
# File 'lib/osso/lib/saml_handler.rb', line 5 def provider @provider end |
#session ⇒ Object
Returns the value of attribute session.
5 6 7 |
# File 'lib/osso/lib/saml_handler.rb', line 5 def session @session end |
Class Method Details
.perform(**attrs) ⇒ Object
7 8 9 |
# File 'lib/osso/lib/saml_handler.rb', line 7 def self.perform(**attrs) new(attrs).perform end |
Instance Method Details
#perform ⇒ Object
17 18 19 20 21 |
# File 'lib/osso/lib/saml_handler.rb', line 17 def perform validate_attributes provider.active! redirect_uri end |