Last active
February 17, 2022 16:05
-
-
Save jppommet/6056932 to your computer and use it in GitHub Desktop.
nodejs crypto sha1 hash in hexadecimal string representation.
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
// We use crypto.randomBytes(20) as an example to generate the seed with a higher entropy, higher number of unique values | |
var hash = crypto.createHash('sha1').update(crypto.randomBytes(20)).digest('hex') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
cool