go-aws-auth
go-aws-auth copied to clipboard
MissingAuthenticationTokenException
When I print the response, I get a 403 Forbidden with the following error MissingAuthenticationTokenException. I have nevertheless added the SecurityToken generated with
$ aws sts get_session-token
What am I doing wrong ? The error should be at least : WrongToken
Thank you
Edit
After calling :
awsauth.Sign(req)
req.Header is an empty map. Shouldn't it be populated with signed attributes ?
Edit 2
You may have inverted indexes, at least for my issue where host = "https://xxxxxxxxxx.execute-api.us-east-1.amazonaws.com"
Should be :
-
service
at index 1 -
region
at index 2
https://github.com/smartystreets/go-aws-auth/blob/0c1422d1fdb9fef5a1ad5b2e13ac663467eb767e/common.go#L49-L50