aws-sdk-s3 1.93.1 → 1.94.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
  SHA256:
3
- metadata.gz: 9720f4044b674d912ad1b52f866a0d433358503dd6cf4d8aa11391619674a15d
4
- data.tar.gz: 6e6ddada3db5629e08660364136608876ce4bac0076ad31a203dd90d9ad52c17
3
+ metadata.gz: '094e61334fb27d9edd1666450c6a08902d650f172c03285254bffb967b9fa9ab'
4
+ data.tar.gz: f864356a00540fac9606874ef3d754448354e9353a73ef8d337718534e218e1b
5
5
  SHA512:
6
- metadata.gz: 769072321971f35f4fc668628908f9efeb4565a90a7aa1575fe71b59d01e6049899e48d468c59dd2fb540cdccb5fbe5de70dacebbc2081fd578a326cf5a93d23
7
- data.tar.gz: 449f8325e0e316b16cff1e0fef1e108072cd5aade0eb4581db803645d9568fb925b6472ae95d6694666b819cb4606830a6d7606d71a476b077d4af66e80ba4fd
6
+ metadata.gz: e6355b5f02d3b3d68fbcb8c75787a767044dec23c1997ae0b3706d65faabf1a3fade04c951e042b4ae9528f4e4f9b113ba71ae0fbca3da69b09b632db5d887d0
7
+ data.tar.gz: da2145f461223e7a53e15f3760a80f474add0024936798e0667b74642d57eee109e88f0fa067f7c24c8db5e31d8d3ac474cb2649ba44072523b4a1b617ce7379
data/CHANGELOG.md CHANGED
@@ -1,6 +1,11 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.94.0 (2021-04-27)
5
+ ------------------
6
+
7
+ * Feature - Allow S3 Presigner to sign non http verbs like (upload_part, multipart_upload_abort, etc.) #2511
8
+
4
9
  1.93.1 (2021-04-12)
5
10
  ------------------
6
11
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.93.1
1
+ 1.94.0
data/lib/aws-sdk-s3.rb CHANGED
@@ -69,6 +69,6 @@ require_relative 'aws-sdk-s3/event_streams'
69
69
  # @!group service
70
70
  module Aws::S3
71
71
 
72
- GEM_VERSION = '1.93.1'
72
+ GEM_VERSION = '1.94.0'
73
73
 
74
74
  end
@@ -13910,7 +13910,7 @@ module Aws::S3
13910
13910
  params: params,
13911
13911
  config: config)
13912
13912
  context[:gem_name] = 'aws-sdk-s3'
13913
- context[:gem_version] = '1.93.1'
13913
+ context[:gem_version] = '1.94.0'
13914
13914
  Seahorse::Client::Request.new(handlers, context)
13915
13915
  end
13916
13916
 
@@ -153,21 +153,35 @@ module Aws
153
153
  # obj.presigned_url(:put, acl: 'public-read')
154
154
  # #=> "https://bucket-name.s3.amazonaws.com/object-key?..."
155
155
  #
156
- # @param [Symbol] http_method
157
- # The HTTP method to generate a presigned URL for. Valid values
158
- # are `:get`, `:put`, `:head`, and `:delete`.
156
+ # @example Pre-signed UploadPart PUT
157
+ #
158
+ # # the object uploaded using this URL will be publicly accessible
159
+ # obj.presigned_url(:upload_part, part_number: 1, upload_id: 'uploadIdToken')
160
+ # #=> "https://bucket-name.s3.amazonaws.com/object-key?..."
161
+ #
162
+ # @param [Symbol] method
163
+ # The S3 operation to generate a presigned URL for. Valid values
164
+ # are `:get`, `:put`, `:head`, `:delete`, `:create_multipart_upload`,
165
+ # `:list_multipart_uploads`, `:complete_multipart_upload`,
166
+ # `:abort_multipart_upload`, `:list_parts`, and `:upload_part`.
159
167
  #
160
168
  # @param [Hash] params
161
169
  # Additional request parameters to use when generating the pre-signed
162
170
  # URL. See the related documentation in {Client} for accepted
163
171
  # params.
164
172
  #
165
- # | HTTP Method | Client Method |
166
- # |---------------|------------------------|
167
- # | `:get` | {Client#get_object} |
168
- # | `:put` | {Client#put_object} |
169
- # | `:head` | {Client#head_object} |
170
- # | `:delete` | {Client#delete_object} |
173
+ # | Method | Client Method |
174
+ # |------------------------------|------------------------------------|
175
+ # | `:get` | {Client#get_object} |
176
+ # | `:put` | {Client#put_object} |
177
+ # | `:head` | {Client#head_object} |
178
+ # | `:delete` | {Client#delete_object} |
179
+ # | `:create_multipart_upload` | {Client#create_multipart_upload} |
180
+ # | `:list_multipart_uploads` | {Client#list_multipart_uploads} |
181
+ # | `:complete_multipart_upload` | {Client#complete_multipart_upload} |
182
+ # | `:abort_multipart_upload` | {Client#abort_multipart_upload} |
183
+ # | `:list_parts` | {Client#list_parts} |
184
+ # | `:upload_part` | {Client#upload_part} |
171
185
  #
172
186
  # @option params [Boolean] :virtual_host (false) When `true` the
173
187
  # presigned URL will use the bucket name as a virtual host.
@@ -188,10 +202,15 @@ module Aws
188
202
  #
189
203
  # @return [String]
190
204
  #
191
- def presigned_url(http_method, params = {})
205
+ def presigned_url(method, params = {})
192
206
  presigner = Presigner.new(client: client)
207
+
208
+ if %w(delete head get put).include?(method.to_s)
209
+ method = "#{method}_object".to_sym
210
+ end
211
+
193
212
  presigner.presigned_url(
194
- "#{http_method.downcase}_object",
213
+ method.downcase,
195
214
  params.merge(bucket: bucket_name, key: key)
196
215
  )
197
216
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-s3
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.93.1
4
+ version: 1.94.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: 2021-04-12 00:00:00.000000000 Z
11
+ date: 2021-04-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-kms
@@ -183,8 +183,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
183
183
  - !ruby/object:Gem::Version
184
184
  version: '0'
185
185
  requirements: []
186
- rubyforge_project:
187
- rubygems_version: 2.7.6.2
186
+ rubygems_version: 3.1.6
188
187
  signing_key:
189
188
  specification_version: 4
190
189
  summary: AWS SDK for Ruby - Amazon S3