Skip to content

Commit

Permalink
[s3] fix s3 signing with query params, accidently made it too lax whi…
Browse files Browse the repository at this point in the history
…le working on versioning, etc
  • Loading branch information
geemus committed May 14, 2010
1 parent 393dea3 commit 2b203a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/fog/aws/s3.rb
Expand Up @@ -203,7 +203,7 @@ def signature(params)
canonical_resource << "#{CGI.escape(subdomain).downcase}/"
end
canonical_resource << "#{params[:path]}"
if params[:query] && !params[:query].empty?
if ['acl', 'location', 'logging', 'requestPayment', 'torrent', 'versioning'].include?(params[:query])
canonical_resource << "?#{params[:query]}"
end
string_to_sign << "#{canonical_resource}"
Expand Down

0 comments on commit 2b203a5

Please sign in to comment.