Last active
November 16, 2015 18:12
-
-
Save JohnL4/64f8f8eb5f4f5a640548 to your computer and use it in GitHub Desktop.
PowerShell snipper to make an MD5 hash string from an arbitrary string
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
$stringToBeHashed = "[email protected]" | |
$md5Hash = [Security.Cryptography.MD5]::Create() | |
$hashBytes = $md5Hash.ComputeHash($stringToBeHashed.ToCharArray()) | |
$hashString = "" | |
foreach ($b in $hashBytes) { $hashString = $hashString + $b.ToString("x2")} | |
$hashString | |
# http://www.gravatar.com/avatar/cd0858865a889264c5d383a0abca2eaf?d=identicon |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment