Class: Api::OpenidConnect::AuthorizationPoint::EndpointStartPoint

Inherits:
Endpoint
  • Object
show all
Defined in:
lib/api/openid_connect/authorization_point/endpoint_start_point.rb

Instance Attribute Summary

Attributes inherited from Endpoint

#app, #nonce, #o_auth_application, #redirect_uri, #request_object, #request_uri, #response_type, #scopes, #user

Instance Method Summary collapse

Methods inherited from Endpoint

#build_attributes, #initialize

Constructor Details

This class inherits a constructor from Api::OpenidConnect::AuthorizationPoint::Endpoint

Instance Method Details

#build_from_request_object(req) ⇒ Object


7
8
9
10
11
12
13
# File 'lib/api/openid_connect/authorization_point/endpoint_start_point.rb', line 7

def build_from_request_object(req)
  request_object = build_request_object(req)
  return unless request_object
  claims = request_object.raw_attributes.with_indifferent_access[:claims].try(:[], :userinfo).try(:keys)
  return unless claims
  req.update_param("scope", req.scope + claims)
end

#handle_response_type(req, _res) ⇒ Object


15
16
17
# File 'lib/api/openid_connect/authorization_point/endpoint_start_point.rb', line 15

def handle_response_type(req, _res)
  @response_type = req.response_type
end