aws-sdk-sns 1.0.0.rc11 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 04d90f5cc18d938c68a75f6bedd343716df4c253
4
- data.tar.gz: 5dc2c654548b46cc312bb5a062844c51e27c2b09
3
+ metadata.gz: 08b7f548dc1ca7798b9e6cdd700a6ba3ed67626e
4
+ data.tar.gz: 6f53dfe2e123d1252e0f4b17639af166e26a729a
5
5
  SHA512:
6
- metadata.gz: 8ec080564a8c31dc548f0ecb7ecf517ebc5404674f265b4e4a3c3a050cd1d07b3891057b0ff5a6f5446ef28d8b7d4bb9424746213799c125a76a0c2b061791c8
7
- data.tar.gz: 307c2db41cb80d3931f5304c0bc84dddf8e96173f080cf88790698c373f327d2a3b73a0f58c32f07c6b38b6c1a2d4bfe8c91da76d08d250b394a1c0d1375043c
6
+ metadata.gz: c0b93829aa033c346b34fa178f3fcee51cb417c0491b684c8f1841bf51466c944514405256de02c727320e093f8cafa84e55de341549ebcf1ec9128547827f5a
7
+ data.tar.gz: e347f85c8ce0c3e1dbdd400dbfd673888f8176a031102568a9279d99b51a8a985767bdd3dcfffa18c14d1ba601f434bb963ccb7ad560de708fa360c5dc22cff0
@@ -46,6 +46,6 @@ require_relative 'aws-sdk-sns/customizations'
46
46
  # @service
47
47
  module Aws::SNS
48
48
 
49
- GEM_VERSION = '1.0.0.rc11'
49
+ GEM_VERSION = '1.0.0'
50
50
 
51
51
  end
@@ -1592,7 +1592,7 @@ module Aws::SNS
1592
1592
  params: params,
1593
1593
  config: config)
1594
1594
  context[:gem_name] = 'aws-sdk-sns'
1595
- context[:gem_version] = '1.0.0.rc11'
1595
+ context[:gem_version] = '1.0.0'
1596
1596
  Seahorse::Client::Request.new(handlers, context)
1597
1597
  end
1598
1598
 
@@ -59,6 +59,7 @@ module Aws
59
59
  # verification.
60
60
  def authenticate!(message_body)
61
61
  msg = Json.load(message_body)
62
+ msg = convert_lambda_msg(msg) if is_from_lambda(msg)
62
63
  if public_key(msg).verify(sha1, signature(msg), canonical_string(msg))
63
64
  true
64
65
  else
@@ -69,6 +70,19 @@ module Aws
69
70
 
70
71
  private
71
72
 
73
+ def is_from_lambda(message)
74
+ message.key? 'SigningCertUrl'
75
+ end
76
+
77
+ def convert_lambda_msg(message)
78
+ cert_url = message.delete('SigningCertUrl')
79
+ unsubscribe_url = message.delete('UnsubscribeUrl')
80
+
81
+ message['SigningCertURL'] = cert_url
82
+ message['UnsubscribeURL'] = unsubscribe_url
83
+ message
84
+ end
85
+
72
86
  def sha1
73
87
  OpenSSL::Digest::SHA1.new
74
88
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-sns
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0.rc11
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-16 00:00:00.000000000 Z
11
+ date: 2017-08-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 3.0.0.rc20
19
+ version: '3'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 3.0.0.rc20
26
+ version: '3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: aws-sigv4
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -73,9 +73,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
73
73
  version: '0'
74
74
  required_rubygems_version: !ruby/object:Gem::Requirement
75
75
  requirements:
76
- - - ">"
76
+ - - ">="
77
77
  - !ruby/object:Gem::Version
78
- version: 1.3.1
78
+ version: '0'
79
79
  requirements: []
80
80
  rubyforge_project:
81
81
  rubygems_version: 2.5.1