Class: AWS::S3::Authentication::Signature

Inherits:
String show all
Defined in:
lib/aws/s3/authentication.rb

Overview

Signature is the abstract super class for the Header and QueryString authentication methods. It does the job of computing the canonical_string using the CanonicalString class as well as encoding the canonical string. The subclasses parameterize these computations and arrange them in a string form appropriate to how they are used, in one case a http request header value, and in the other case key/value query string parameter pairs.

Direct Known Subclasses

Header, QueryString

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from String

#previous, #previous!, #remove_extended, #remove_extended!, #tap, #to_header, #underscore, #valid_utf8?

Constructor Details

#initialize(request, access_key_id, secret_access_key, options = {}) ⇒ Signature

Returns a new instance of Signature



55
56
57
58
59
# File 'lib/aws/s3/authentication.rb', line 55

def initialize(request, access_key_id, secret_access_key, options = {})
  super()
  @request, @access_key_id, @secret_access_key = request, access_key_id, secret_access_key
  @options = options
end

Instance Attribute Details

#access_key_idObject (readonly)

:nodoc:



53
54
55
# File 'lib/aws/s3/authentication.rb', line 53

def access_key_id
  @access_key_id
end

#optionsObject (readonly)

:nodoc:



53
54
55
# File 'lib/aws/s3/authentication.rb', line 53

def options
  @options
end

#requestObject (readonly)

:nodoc:



53
54
55
# File 'lib/aws/s3/authentication.rb', line 53

def request
  @request
end

#secret_access_keyObject (readonly)

:nodoc:



53
54
55
# File 'lib/aws/s3/authentication.rb', line 53

def secret_access_key
  @secret_access_key
end