Add hashing utils and update tar utils.

This is some of the stuff I've written while working on backups.  I'd rather not sequester it away under juju core.