aws-sdk-js: using pre-signed url for PUT returns SignatureDoesNotMatch using SSE-C
If I use ServerSideEncryption
this entire workflow is perfect. I can upload a file using the pre-signed url and offer a link to my end users without having to send any header information (in the PUT or GET).
However, switching over to use SSECustomerKey causes the same workflow to error out.
It generates the proper signed url for a PUT request, but when I attempt to upload it fails with a SignatureDoesNotMatch error.
I have seen in some other tickets that you have to send the same headers across when using a signedurl. However, I’m not sending those headers across when I use ServerSideEencryption and it works fine.
I was hoping and assumed that because the signed url includes the header information in the query string that it would just work. Which it does for sse. The moment I switch it to sse-c it errors out.
If I do have to send the headers for sse-c… how am I supposed to offer a link for people to click on our site? And why does it work for sse, but not sse-c?
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 35 (12 by maintainers)
hey @Timer here is the OpenResty configuration we used for prototyping the solution. You need to use openresty, as it has functionality that isn’t available with nginx ootb.