Module: AWS::Core::Signature::Version4
- Defined in:
- lib/aws/core/signature/version_4.rb
Instance Method Summary collapse
Instance Method Details
#add_authorization!(signer) ⇒ Object
23 24 25 26 27 28 29 30 31 |
# File 'lib/aws/core/signature/version_4.rb', line 23 def signer self.access_key_id = signer.access_key_id datetime = Time.now.utc.strftime("%Y%m%dT%H%M%SZ") headers['content-type'] ||= 'application/x-www-form-urlencoded' headers['host'] = host headers['x-amz-date'] = datetime headers['x-amz-security-token'] = signer.session_token if signer.session_token headers['authorization'] = (signer, datetime) end |