Start a new topic

Kinvey.File.upload - Google Cloud Storage returns 403 Forbidden

Google Cloud Storage is returning the following error when attempting to upload a file via the HTML5 function Kinvey.File.upload:

SignatureDoesNotMatchThe request signature we calculated does not match the signature you provided. Check your Google secret key and signing method.PUT:text/html; charset=UTF-8 1407189186 x-goog-acl:public-read /kinvey_production_ce3e3fb1d1bb441ca0bb3b6c1510580b/a388f753-5374-49c0-9ef8-3a7f500de2d7/dbad63b1-bf95-4d3e-8137-7f90db5b8951

NetworkError: 403 Forbidden -

Request headers include:

Accept text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8

Accept-Encoding gzip, deflate

Accept-Language en-US,en;q=0.5

Cache-Control private, max-age=0, no-transform

Content-Length 11

Content-Type text/html; charset=UTF-8


Origin http://localhost:3000

Referer http://localhost:3000/

User-Agent Mozilla/5.0 (Windows NT 6.3; WOW64; rv:32.0) Gecko/20100101 Firefox/32.0

x-goog-acl public-read

It looks like Kinvey is returning a bad signature?

Interesting, I'm also getting a `SignatureDoesNotMatch` error, only on []( Upload is working fine.
Any change for you? Still happening here.
No joy and no community support by Kinvey. Time to look elsewhere.
Hey Ryan and Adam,

This is definitely strange behavior and we're investigating now. I will keep you posted!
I am able to reproduce your problem in Firefox 32, this seems a browser-specific issue. Can you try specifying the mime type when uploading, like:


Kinvey.File.upload(, { mimeType: 'application/octet-stream; charset=UTF-8' });

Thank you Mark. This resolves the issue.

It appears "; chartset=UTF-8" is being appended to the mimeType request to Google Cloud Storage but not being specified in the Kinvey API request. Therefore the signature is invalid.
Yeah, seems to be something that differs between browsers. Firefox appends the charset if you don’t specify it (therefore invalidating the signature), however Chrome doesn’t seem to do that (yet...).
Login or Signup to post a comment