fix s3 requests sent to outpost arn missing x-amz-content-sha256 header #4857
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Example code of testing an outpost endpoint. NOTE: You don't actually have to have an outpost endpoint setup, just plugin your own account and a dummy value for the access point (e.g.
my-test-access-point
).output contains
The resolved endpoint is an outpost ARN which customizes the signing name to be
s3-outposts
instead ofs3
. Requests to S3 must include thex-amz-content-sha256
header but the the v4 signer does not special cases3-outposts
to include the header.This change does affect the actual
s3outpost
service requests as it shares the same signing name. I've tested that requests with and without the header have the same responses and that it's valid and safe to send this for s3outposts as well.Go v2 doesn't have this issue since middleware is registered on the operation to add this particular header for S3 requests.