MD5 File Hashing - match Delphi output with PHP md5_file function

后端 未结 2 1227
南笙
南笙 2021-01-07 05:03

I\'m currently using this code for md5 hashing in Delphi 7:

function MD5(const fileName : string) : string;
var
  idmd5 : TIdHashMessageDigest5;
  fs : TFile         


        
2条回答
  •  旧巷少年郎
    2021-01-07 05:46

    Compare your results with:

    • md5(file_get_contents( )) in PHP

    • hash("md5", ) from the PHP hash framework extension

    • the command line programs md5(1) aka md5sum(1)

    If all but one agree what the sum is, then you know where to dig.

提交回复
热议问题