Is there a .NET library that can sign a request with AWS V4 Signature?

While this is an old question, since AWS has not "prioritized accordingly" with regards to the .NET AWS SDK as stated in their comment above and this is still a relevant problem today, I found a good library that will take care of the AWS V4 request signing for you.

Here is the Nuget package.

Here is the GitHub source and implementation documentation.

In addition, I've found that for my API Gateway AWS_IAM Authorization to work with temporary security credentials, you also need to include the "x-amz-security-token" header with the current session token as it's value as well in your request.


you can read on how the signature is done and you can (if you want). I would recommend pulling in the AWS SDK for .NET and using the functionality from the SDK to actually perform the signature.

Here is the signer form the SDK:

https://github.com/aws/aws-sdk-net/blob/6c3be79bdafd5bfff1ab0bf5fec17abc66c7b516/sdk/src/Core/Amazon.Runtime/Internal/Auth/AWS4Signer.cs

You may need to adapt it (ie it knows about AWS services and endpoints by default)