Last active
June 20, 2018 08:40
-
-
Save MosheBerman/8e06db9e34707a72883e to your computer and use it in GitHub Desktop.
A Python script to hash domain names.
This file contains hidden or 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
import hashlib | |
import sys | |
try: | |
website_name = sys.argv[1] | |
hash_value = hashlib.md5(website_name) | |
print(hash_value.hexdigest().upper() + ".png") | |
except Exception, e: | |
print "Usage: " + sys.argv[0] + " {domain.com}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Save this script, then run:
python hash.py domain.com
This example gives us
7905D1C4E12C54933A44D19FCD5F9356.png
.