Skip to content
This repository has been archived by the owner on Apr 20, 2024. It is now read-only.

Commit

Permalink
Merge pull request #23 from ahusseini/issue/22
Browse files Browse the repository at this point in the history
dictionary returned from sign function now includes headers passed to it
  • Loading branch information
BrettRToomey authored May 16, 2017
2 parents 3d544ed + 78ec339 commit d36da21
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions Sources/AWSSignatureV4/AWSSignatureV4.swift
Original file line number Diff line number Diff line change
Expand Up @@ -192,11 +192,19 @@ extension AWSSignatureV4 {
signature: signature,
signedHeaders: signedHeaders
)

return [


var requestHeaders: [HeaderKey: String] = [
"X-Amz-Date": amzDate,
"x-amz-content-sha256": payloadHash,
"Authorization": authorizationHeader
]

headers.forEach { key, value in
let headerKey = HeaderKey(stringLiteral: key)
requestHeaders[headerKey] = value
}

return requestHeaders
}
}

0 comments on commit d36da21

Please sign in to comment.