Skip to content

Instantly share code, notes, and snippets.

@bergantine
Last active November 20, 2019 13:38
Show Gist options
  • Save bergantine/2623697 to your computer and use it in GitHub Desktop.
Save bergantine/2623697 to your computer and use it in GitHub Desktop.
Create md5 Hash of a File using Python. #python #md5 #hash
import hashlib
filehash = hashlib.md5()
filehash.update(open('/path/to/file.zip').read())
print filehash.hexdigest()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment