Last active
October 7, 2015 04:28
-
-
Save esbullington/3105926 to your computer and use it in GitHub Desktop.
Quick and easy command line script to compare sha1sum of a file and the sha1sum string (eliminates need to create a file)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ $(sha1sum /path/to/file/to/check.txt | awk '{printf "%s", $1}') = "1a5091_SHA1_TO_CHECK_443234" ] && echo "Pass: sha1sum match" || echo "Warning: no match" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Updated md5sum to sha1sum, a more appropriate hashing algorithm for the present day.