I'm trying to sign the :put_object operation with Aws::S3::Presigner but the :content_type option is ignored. Content-Type is neither in the X-Amz-SignedHeaders parameter not anywhere else to be found.
signer = Aws::S3::Presigner.new
@url = signer.presigned_url(:put_object,
bucket: bucket,
key: 'test.jpg',
acl: 'public-read',
content_type: 'image/png',
metadata: { "MetadataKey" => "MetadataValue" }
)
generates:
https://bucket.s3.eu-central-1.amazonaws.com/test.jpg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=XXXXXXXXXXXXXXXXXXXX%2F20150227%2Feu-central-1%2Fs3%2Faws4_request&X-Amz-Date=20150227T010602Z&X-Amz-Expires=900&X-Amz-SignedHeaders=host&x-amz-acl=public-read&x-amz-meta-metadatakey=MetadataValue&X-Amz-Signature=e351ac84cfd552968229da20eacdc1d31f854398a9fa6da44f0f982b6e09d2f9
I'm trying to sign the
:put_objectoperation withAws::S3::Presignerbut the:content_typeoption is ignored.Content-Typeis neither in theX-Amz-SignedHeadersparameter not anywhere else to be found.generates:
https://bucket.s3.eu-central-1.amazonaws.com/test.jpg?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=XXXXXXXXXXXXXXXXXXXX%2F20150227%2Feu-central-1%2Fs3%2Faws4_request&X-Amz-Date=20150227T010602Z&X-Amz-Expires=900&X-Amz-SignedHeaders=host&x-amz-acl=public-read&x-amz-meta-metadatakey=MetadataValue&X-Amz-Signature=e351ac84cfd552968229da20eacdc1d31f854398a9fa6da44f0f982b6e09d2f9