Created
August 17, 2017 19:25
Star
You must be signed in to star a gist
MD5 hash Delphi
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
class function getMd5HashString(value: string): string; | |
var | |
hashMessageDigest5 : TIdHashMessageDigest5; | |
begin | |
hashMessageDigest5 := nil; | |
try | |
hashMessageDigest5 := TIdHashMessageDigest5.Create; | |
Result := IdGlobal.IndyLowerCase ( hashMessageDigest5.HashStringAsHex ( value ) ); | |
finally | |
hashMessageDigest5.Free; | |
end; | |
end; | |
// From: | |
// https://stackoverflow.com/questions/58621/how-do-i-hash-a-string-with-delphi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment