Class: Rack::OAuth2::AssertionProfile::Request

Inherits:
Request
  • Object
show all
Defined in:
lib/rack/oauth2/assertion_profile.rb

Overview

Internal class used to parse the current request based on the enviroment parameters.

Instance Method Summary collapse

Constructor Details

#initialize(env) ⇒ Request

Returns a new instance of Request.



56
57
58
# File 'lib/rack/oauth2/assertion_profile.rb', line 56

def initialize(env)
  super(env)
end

Instance Method Details

#assertion_profile?Boolean

Returns a value indicating whether the type the of authorization request is assertion

Returns:

  • (Boolean)


62
63
64
# File 'lib/rack/oauth2/assertion_profile.rb', line 62

def assertion_profile?
  self.params["type"] =~ /assertion/i
end

#formatObject

Reads from the formvars the format of the set assertion



68
69
70
# File 'lib/rack/oauth2/assertion_profile.rb', line 68

def format
  (self.params["format"] or "saml").downcase.to_sym
end

#tokenObject

Reads the assertion from the given formvars



73
74
75
# File 'lib/rack/oauth2/assertion_profile.rb', line 73

def token
  self.params["assertion"]
end