Thursday, April 10, 2014

MultiHash tool created

I've built a new tool to add to the Infix Technologies collection. This one may be a bit obscure to most, but to some of you it may be a real time saver. MultiHash creates MD5 hashes for single files, sets of files, directory trees, or even entire drives.

"So what," you ask? Have you ever downloaded ISO files for something like a Linux distribution and seen a big long string labelled "MD5 Hash" that looks something like this?
5DB1C92CA8900310863D08EFA698E958
This tool can be used to verify that what you downloaded is exactly what they say it is. If you calculate the hash on the ISO after downloading, and your hash is not an exact match for theirs, someone was naughty and modified the ISO without telling you.

Another use for this tool, albeit a fairly limited one, is for verification of duplicate sets of files. As an example, software escrow companies need to be given multiple identical copies of the data to be put into escrow. How do you verify that they are identical? You can do it a couple of different ways.

  1. Build an MD5 hash for each file. This can be interesting if you happen to have 25000 files.
  2. Build an MD5 hash for a zip file containing everything. These can get really big, but it gives you just one hash.
If you went with option 1, the problem is that you have a whole set of hashes to verify as identical. The trick with MultiHash is that it builds a text file which contains a descriptive header, and then includes every hash value and the file name associated with it. The fun part is that it calculates a hash for that file. In effect, it is a grand overall sum hash so you can verify that two large sets of files are identical without having to put them into a monstrous zip file first.

As a side note, this is my first real try at building an app which uses the publishing features in Microsoft's Visual Studio 2013. It seems to have done a good job, but it's a little too bare-bones. I ended up writing some custom tools to change the name of the installer, and to customize the generic install web page to match.

Here's what MultiHash looks like. Noting too special, other than I used MVVM in WPF. That made it easy to make things size dynamically.


Let me know what you think about MultiHash.

No comments: