Created
April 20, 2015 01:38
-
-
Save berlotto/c861e95076b878c2786d to your computer and use it in GitHub Desktop.
Generate tokens in Python
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
#http://wyattbaldwin.com/2014/01/09/generating-random-tokens-in-python/ | |
import os | |
import hashlib | |
print hashlib.sha1(os.urandom(128)).hexdigest() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment