Checksums for file uploads made directly to a bucket

Please refer to this guide:

There is a link there which is dead: (Search for the following text):

See this walkthrough for a complete JavaScript implementation of checksums.

I added a gist written by janko gist into the wiki, but realised that the wiki has a history of revisions - but then again, perhaps it was deleted for a reason?

regardless: do any of you have sample code on dealing with checksums on direct uploads to a bucket on the client side?