i.crave.beer – The online home of Joshua Skorich

3rd March 2014

PyHash

I wrote a basic Python script today for generating hashes. The entire driving factor for this was the lack of hashing functionality in many operating systems, Windows specifically. I've used FCIV in Windows before, but generating anything above a SHA1 hash on Windows (7 specifically) is still cumbersome.

There are thousands of other tools out there, but if you want a simple Python 2.X tool for the task feel free to use at your discretion.

Available at https://github.com/joshuaskorich/PyHash

Simple usage:
./PyHash options filename

Options:
no flags : Calculate all hashes (MD5, SHA1, SHA224, SHA256, SHA384, SHA512)
--md5 : Calculate a MD5 hash
--sha1 : Calculate a SHA1 hash
--sha224 : Calculate a SHA224 hash
--sha256 : Calculate a SHA256 hash
--sha384 : Calculate a SHA384 hash
--sha512 : Calculate a SHA512 hash
-f : Output hash(es) to a specified file