Class: Aws::Plugins::Sign Private

Inherits:
Seahorse::Client::Plugin show all
Defined in:
lib/aws-sdk-core/plugins/sign.rb

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

Defined Under Namespace

Classes: Bearer, Handler, NullSigner, SignatureV4

Constant Summary collapse

SUPPORTED_AUTH_TYPES =

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.

supported_auth_types.freeze

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Seahorse::Client::Plugin

#add_options, #after_initialize, after_initialize, after_initialize_hooks, before_initialize, #before_initialize, before_initialize_hooks, handlers, literal, option, options

Methods included from Seahorse::Client::HandlerBuilder

#handle, #handle_request, #handle_response, #handler_for, #new_handler

Class Method Details

.signer_for(auth_scheme, config, sigv4_region_override = nil, sigv4_credentials_override = nil) ⇒ 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.

Return a signer with the ‘sign(context)` method



27
28
29
30
31
32
33
34
35
36
37
38
39
40
# File 'lib/aws-sdk-core/plugins/sign.rb', line 27

def self.signer_for(auth_scheme, config, sigv4_region_override = nil, sigv4_credentials_override = nil)
  case auth_scheme['name']
  when 'sigv4', 'sigv4a', 'sigv4-s3express'
    sigv4_overrides = {
      region: sigv4_region_override,
      credentials: sigv4_credentials_override
    }
    SignatureV4.new(auth_scheme, config, sigv4_overrides)
  when 'bearer'
    Bearer.new
  else
    NullSigner.new
  end
end

Instance Method Details

#add_handlers(handlers, cfg) ⇒ 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.



20
21
22
23
# File 'lib/aws-sdk-core/plugins/sign.rb', line 20

def add_handlers(handlers, cfg)
  operations = cfg.api.operation_names - cfg.unsigned_operations
  handlers.add(Handler, step: :sign, operations: operations)
end