View Single Post
  #4  
Old 03-04-2016, 05:28
peterf1999's Avatar
peterf1999 peterf1999 is offline
Die Hard Member
 
Join Date: Nov 2008
Location: Italy
Posts: 928
Thanks: 14
Thanked 983 Times in 236 Posts
peterf1999 is on a distinguished road
  • Renamed 'GetFileSHA1' function to 'GetFileHash'.
  • function prototype changes.
  • Added support for SHA512(SHA-2) hash algorithm to both functions (GetFileHash, CheckFileHash).
Code:
const
  DCP_MD5 = 1;
  DCP_SHA1 = 2;
  DCP_SHA256 = 4; // SHA-2
  DCP_SHA512 = 8; //SHA-2
Code:
function GetFileHash(const Filename: PAnsichar; const DCP_Hash: integer): PAnsichar; external 'GetFileHash@files:Isab.dll stdcall delayload';
Reply With Quote
The Following 4 Users Say Thank You to peterf1999 For This Useful Post:
arkantos7 (06-04-2016), Razor12911 (09-04-2016), Simorq (14-09-2017), y_thelastknight (07-04-2016)