signature-v2: Use request.RequestURI for signature calculation. (#3616)

* signature-v2: Use request.RequestURI for signature calculation.

* Use splitStr instead of strings.Split
This commit is contained in:
Krishna Srinivas
2017-01-23 17:01:44 -08:00
committed by Harshavardhana
parent fc6f804865
commit 8489f22fe2
3 changed files with 18 additions and 28 deletions

View File

@@ -101,6 +101,8 @@ func TestDoesPresignedV2SignatureMatch(t *testing.T) {
if e != nil {
t.Errorf("(%d) failed to create http.Request, got %v", i, e)
}
// Should be set since we are simulating a http server.
req.RequestURI = req.URL.RequestURI()
// Do the same for the headers.
for key, value := range testCase.headers {