Return ErrContentSHA256Mismatch when sha256sum is invalid (#5188)

This commit is contained in:
Krishnan Parthasarathi
2017-11-16 19:13:04 +00:00
committed by Dee Koder
parent 67f66c40c1
commit 2a0a62b78d
3 changed files with 24 additions and 15 deletions

View File

@@ -289,7 +289,7 @@ func doesPresignedSignatureMatch(hashedPayload string, r *http.Request, region s
/// Verify finally if signature is same.
// Get canonical request.
presignedCanonicalReq := getCanonicalRequest(extractedSignedHeaders, unsignedPayload, encodedQuery, req.URL.Path, req.Method)
presignedCanonicalReq := getCanonicalRequest(extractedSignedHeaders, hashedPayload, encodedQuery, req.URL.Path, req.Method)
// Get string to sign from canonical request.
presignedStringToSign := getStringToSign(presignedCanonicalReq, t, pSignValues.Credential.getScope())