aws-sdk-sns 1.32.0 → 1.32.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ea4426c2b03ba5b4ae9bacf79b6642667a345c50519bbcfdb1decffab1a83d79
4
- data.tar.gz: 3a3b5dee8291694fbb39cdffbcda6d2dbfb33369b9d9724bd2ebbf53d7cd86a8
3
+ metadata.gz: 26b3c7ca043707d291ea47c619e2b0481b24282b95f57f031a7bca55d477fb6c
4
+ data.tar.gz: 0f12afc9f439d81955cbe98497e47e360e7fdd97cc2ff177122e9e4b1000e393
5
5
  SHA512:
6
- metadata.gz: 4ea954b627d0f60b12a3ad5f3d60b01dff2c5c813649c6f93936dbfe71d177317eac0eb5e3c5400097377bb394e278eae95fd87e683921ab27af5a3bbc5c8733
7
- data.tar.gz: de71a626b65ff7f70cd0e2955b1d3599dee5c90cc621738f776516539dd84e43dd69f686ada01ddd412a023745bd18db5f9f178defb13a601591e206f3b2cef9
6
+ metadata.gz: 10a4c7eabec788ff54f27ad3125798004d9ca937a80cba277215ff3901460f70fbb6faf1816bf211854073f5fd345097dd3928570418f88d7a809e088d2f8186
7
+ data.tar.gz: 1fe0e8dd6cc7609d6390de957406444b330b240e737da2a74a64d30cd494579235bd591ef4634ee41befdca623e349da6e765583e3c155dcb449c0e627eaa8bd
@@ -52,6 +52,6 @@ require_relative 'aws-sdk-sns/customizations'
52
52
  # @!group service
53
53
  module Aws::SNS
54
54
 
55
- GEM_VERSION = '1.32.0'
55
+ GEM_VERSION = '1.32.1'
56
56
 
57
57
  end
@@ -2071,7 +2071,7 @@ module Aws::SNS
2071
2071
  params: params,
2072
2072
  config: config)
2073
2073
  context[:gem_name] = 'aws-sdk-sns'
2074
- context[:gem_version] = '1.32.0'
2074
+ context[:gem_version] = '1.32.1'
2075
2075
  Seahorse::Client::Request.new(handlers, context)
2076
2076
  end
2077
2077
 
@@ -6,7 +6,6 @@ require 'base64'
6
6
 
7
7
  module Aws
8
8
  module SNS
9
-
10
9
  # A utility class that can be used to verify the authenticity of messages
11
10
  # sent by Amazon SNS.
12
11
  #
@@ -33,16 +32,20 @@ module Aws
33
32
  'Timestamp',
34
33
  'Token',
35
34
  'TopicArn',
36
- 'Type',
35
+ 'Type'
37
36
  ].freeze
38
37
 
39
38
  # @api private
40
39
  AWS_HOSTNAMES = [
41
40
  /^sns\.[a-zA-Z0-9\-]{3,}\.amazonaws\.com(\.cn)?$/
42
- ]
41
+ ].freeze
43
42
 
44
- def initialize
43
+ # @param [Hash] http_options Supported options to be passed to Net::HTTP.
44
+ # @option http_options [String] :http_proxy A proxy to send
45
+ # requests through. Formatted like 'http://proxy.com:123'.
46
+ def initialize(http_options = {})
45
47
  @cached_pems = {}
48
+ @http_proxy = http_options[:http_proxy]
46
49
  end
47
50
 
48
51
  # @param [String<JSON>] message_body
@@ -151,7 +154,11 @@ module Aws
151
154
  end
152
155
 
153
156
  def https_get(uri, failed_attempts = 0)
154
- http = Net::HTTP.new(uri.host, uri.port)
157
+ args = []
158
+ args << uri.host
159
+ args << uri.port
160
+ args += http_proxy_parts
161
+ http = Net::HTTP.new(*args.compact)
155
162
  http.use_ssl = true
156
163
  http.verify_mode = OpenSSL::SSL::VERIFY_PEER
157
164
  http.start
@@ -168,6 +175,16 @@ module Aws
168
175
  raise VerificationError, error.message
169
176
  end
170
177
 
178
+ def http_proxy_parts
179
+ # empty string if not configured, URI parts return nil
180
+ http_proxy = URI.parse(@http_proxy.to_s)
181
+ [
182
+ http_proxy.host,
183
+ http_proxy.port,
184
+ (http_proxy.user && CGI.unescape(http_proxy.user)),
185
+ (http_proxy.password && CGI.unescape(http_proxy.password))
186
+ ]
187
+ end
171
188
  end
172
189
  end
173
190
  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.32.0
4
+ version: 1.32.1
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: 2020-09-30 00:00:00.000000000 Z
11
+ date: 2020-10-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core