Skip to content

Commit

Permalink
don't sign EXPECT header (#1477)
Browse files Browse the repository at this point in the history
  • Loading branch information
johnnyaug authored Feb 17, 2021
1 parent eedd2ee commit 0bf71b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion block/s3/adapter.go
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,6 @@ func (a *Adapter) streamToS3(sdkRequest *request.Request, sizeBytes int64, reade
req.Header.Set("Transfer-Encoding", "chunked")
req.Header.Set("x-amz-content-sha256", StreamingSha256)
req.Header.Set("x-amz-decoded-content-length", fmt.Sprintf("%d", sizeBytes))
req.Header.Set("Expect", "100-Continue")

baseSigner := v4.NewSigner(sdkRequest.Config.Credentials)
baseSigner.DisableURIPathEscaping = true
Expand All @@ -193,6 +192,7 @@ func (a *Adapter) streamToS3(sdkRequest *request.Request, sizeBytes int64, reade
log.WithError(err).Error("failed to sign request")
return "", err
}
req.Header.Set("Expect", "100-Continue")

sigSeed, err := v4.GetSignedRequestSignature(req)
if err != nil {
Expand Down

0 comments on commit 0bf71b7

Please sign in to comment.