Module: Aws::Endpoints Private

Defined in:
lib/aws-sdk-core/endpoints.rb,
lib/aws-sdk-core/endpoints/url.rb,
lib/aws-sdk-core/endpoints/rule.rb,
lib/aws-sdk-core/endpoints/endpoint.rb,
lib/aws-sdk-core/endpoints/function.rb,
lib/aws-sdk-core/endpoints/matchers.rb,
lib/aws-sdk-core/endpoints/rule_set.rb,
lib/aws-sdk-core/endpoints/condition.rb,
lib/aws-sdk-core/endpoints/reference.rb,
lib/aws-sdk-core/endpoints/templater.rb,
lib/aws-sdk-core/endpoints/tree_rule.rb,
lib/aws-sdk-core/endpoints/error_rule.rb,
lib/aws-sdk-core/endpoints/endpoint_rule.rb,
lib/aws-sdk-core/endpoints/rules_provider.rb

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Defined Under Namespace

Modules: Matchers, Templater Classes: Condition, Endpoint, EndpointRule, ErrorRule, Function, Reference, Rule, RuleSet, RulesProvider, TreeRule, URL

Constant Summary collapse

SUPPORTED_AUTH_TRAITS =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

%w[
  aws.auth#sigv4
  aws.auth#sigv4a
  smithy.api#httpBearerAuth
  smithy.api#noAuth
].freeze

Class Method Summary collapse

Class Method Details

.resolve_auth_scheme(context, endpoint) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



30
31
32
33
34
35
36
37
38
39
40
41
# File 'lib/aws-sdk-core/endpoints.rb', line 30

def resolve_auth_scheme(context, endpoint)
  if endpoint && (auth_schemes = endpoint.properties['authSchemes'])
    auth_scheme = auth_schemes.find do |scheme|
      Aws::Plugins::Sign::SUPPORTED_AUTH_TYPES.include?(scheme['name'])
    end
    raise 'No supported auth scheme for this endpoint.' unless auth_scheme

    merge_signing_defaults(auth_scheme, context.config)
  else
    default_auth_scheme(context)
  end
end