Module: OauthIm
- Defined in:
- lib/oauth_im/configuration.rb,
lib/oauth_im.rb,
lib/oauth_im/engine.rb,
lib/oauth_im/version.rb,
app/services/oauth_im/client.rb,
app/services/oauth_im/idp_client.rb,
app/services/oauth_im/proxy_user.rb,
app/services/oauth_im/user_client.rb,
app/services/oauth_im/admin_client.rb,
app/services/oauth_im/token_decoder.rb,
app/services/oauth_im/request_client.rb,
app/helpers/oauth_im/application_helper.rb,
app/services/oauth_im/registration_client.rb,
app/controllers/oauth_im/client_controller.rb,
app/services/oauth_im/has_registration_data.rb,
app/controllers/concerns/oauth_im/authenticable.rb,
app/controllers/oauth_im/application_controller.rb
Overview
# EDC: memoizing state for these methods is problematic. # # without care, an object’s local state can diverge from # # the remote state returned by the API. so for now # # it seems safest to leave things unmemoized #
Defined Under Namespace
Modules: ApplicationHelper, Authenticable, HasRegistrationData Classes: AdminClient, ApplicationController, Client, ClientController, Configuration, ConfigurationProxy, Engine, IdpClient, ProxyUser, RegistrationClient, RequestClient, TokenDecoder, UserClient
Constant Summary collapse
- DEFAULT_AUTH_AUTHORIZE_URL =
'/oauth2/authorize'
- DEFAULT_AUTH_CALLBACK_ROUTE =
'callback'
- DEFAULT_AUTH_TOKEN_URL =
'/oauth2/token'
- DEFAULT_AUTH_ISS_DOMAIN =
'illustrativemathematics.org'
- DEFAULT_AUTH_IDP_URL_LIVE =
'https://login.illustrativemathics.org'
- DEFAULT_AUTH_IDP_URL_TEST =
'https://illustrativemath-dev.fusionauth.io'
- DEFAULT_AUTH_IDP_URL =
DEFAULT_AUTH_IDP_URL_TEST
- VERSION =
'0.17.1'
- CONFIGURABLE_FIELDS =
%i[ api_key authorize_url callback_route token_url idp_url iss_domain client_id client_secret hmac rsa_public oauth_rescue_redirect_path ].freeze
Class Attribute Summary collapse
-
.configuration ⇒ Object
readonly
Returns the value of attribute configuration.
Class Method Summary collapse
Class Attribute Details
.configuration ⇒ Object (readonly)
Returns the value of attribute configuration.
21 22 23 |
# File 'lib/oauth_im.rb', line 21 def configuration @configuration end |
Class Method Details
.callback_route ⇒ Object
33 34 35 |
# File 'lib/oauth_im.rb', line 33 def self.callback_route configuration&.callback_route || DEFAULT_AUTH_CALLBACK_ROUTE end |
.configure ⇒ Object
24 25 26 27 28 29 30 31 |
# File 'lib/oauth_im.rb', line 24 def self.configure raise 'Already configured!' if configuration.present? ConfigurationProxy.new.then do |proxy| yield proxy @configuration = Configuration.new proxy end end |