Has anybody had issues with AWS v4 auth? I am pass...
# suitescript
z
Has anybody had issues with AWS v4 auth? I am passing a canonical string and getting an error back that it should be the same string except for ‘//n’ instead of my passed in ‘/n’.
u
Are you using CryptoJS for this one?
z
Yep!
u
Is that the specific error that AWS is throwing or not?
z
Copy code
"{"message":"The request signature we calculated does not match the signature you provided. Check your AWS Secret Access Key and signing method. Consult the service documentation for details.\\n\\nThe Canonical String for this request should have been\\n'GET\\n/sandbox/restapi/v1/applications/19-11-000322/status\\n\\nhost:HOST\nx-amz-content-sha256:\\nx-amz-date:20200326T154150Z\\n\\nhost;x-amz-content-sha256;x-amz-date\\ne3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'\\n\\nThe String-to-Sign should have been\\n'AWS4-HMAC-SHA256\\n20200326T154150Z\\n20200326/us-west-2/execute-api/aws4_request\\n44a0da9053032746d2d4bda01f119bb60ee92737f720912b22982c708c8503d3'\\n"}\n"
I tried taking their should have been strings and running with those and still getting the error
u
it uses //n just to escape the /n that was in there
do you have your snippet?