aristidb / aws

Amazon Web Services for Haskell
BSD 3-Clause "New" or "Revised" License
239 stars 108 forks source link

Setting poContentMD5 causes authorization failure #243

Open basvandijk opened 6 years ago

basvandijk commented 6 years ago

Setting the poContentMD5 field of the S3.PutObject record causes the following error:

S3Error 
{ s3StatusCode = Status {statusCode = 403, statusMessage = "Forbidden"}
, s3ErrorCode = "AccessDenied"
, s3ErrorMessage = "There were headers present in the request which were not signed"
, s3ErrorResource = Nothing
, s3ErrorHostId = Just "..."
, s3ErrorAccessKeyId = Nothing
, s3ErrorStringToSign = Nothing
, s3ErrorBucket = Nothing
, s3ErrorEndpointRaw = Nothing
, s3ErrorEndpoint = Nothing
}

Note that I'm using the following S3Configuration:

s3Cfg :: S3.S3Configuration Aws.NormalQuery
s3Cfg = S3.s3v4 Aws.HTTPS "..." False S3.SignWithEffort

When I set poContentMD5 to Nothing the request succeeds.