Last active
December 22, 2023 14:53
-
-
Save PSJoshi/88ab9f5bb473b2be82798e6ba5412d14 to your computer and use it in GitHub Desktop.
Hash a web page
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
#!/usr/bin/env python | |
import requests | |
import hashlib | |
page_contents = requests.get('http://www.google.com') | |
response = page_contents.text | |
print hashlib.sha256(response.encode('utf-8')).hexdigest() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment