SignatureDoesnotMatch error when uploading file to google bucket
Hi Team,
I am trying to upload pdf file to google bucket but getting error as below
Code: SignatureDoesNotMatch
Message: The request signature we calculated does not match the signature you provided. Check your Google secret key and signing method.
StringToSign: GOOG4-RSA-SHA256 20221117T141420Z 20221117/auto/storage/goog4_request 31acd2cb4f0901569693fd5a1d894932b20535f4065f67b7a9f21369a0059ae7
CononicalRequest: XXXXXXXXXXXXXXXXXXXXXXXXXXXXx
Any request would be highly appreciated.
Thanks and Regards,
Nishant Prakash
Hey N_P
Looking at the error response and the endpoint you provide I'd suggest you're not providing the correct headers (the "Endpoint" URL you supply launches
I have a look at the screenshot you embedded and it appears that you have lots of x-goog-% query parms.
Should these query parms actually be header parms on the request rather than query parms?
I did try taking a look to find the headers needed on a google bucket upload, but I couldn't find anything that wasnt contradictory (I suspect the headers have changed over time perhaps).
Anyway - if you DO know the correct URI pattern (including query parms) along with the correct header parms, I'd suggest you just need to update the relevant query parms to 'header' in your screenshot.
Worst case - if you are unsure on the headers/query parm combination, you could manually upload a file via your browser (ensuring to proxy the request via Fiddler, which is an HTTP/HTTPS traffic sniffer) - Fiddler will then show you the correct headers/query parms needed to upload a file and then you can do it from within ReadyAPI by emulating the same query/header parms on the request.
Sorry I can't be of more help - but without knowing the correct URI pattern and required headers - this is my best guess!
Cheers,
Rich