现在的位置: 首页 > 综合 > 正文

比较2进制文件(EXE,DLL等)异同的方法

2014年03月08日 ⁄ 综合 ⁄ 共 554字 ⁄ 字号 评论关闭

有时候,需要比较EXE,DLL文件,虽然重新编译了,或者只是版本修改,但是其实内容没有变化。

参考http://support.microsoft.com/kb/164151/en-us

The time and date stamps can be removed from the built image without removing relevant information (code and data) using the /RAWDATA switch available in the DUMPBIN utility. Any file compare utility can then be used on the DUMPBIN output as follows:
   DUMPBIN  /RAWDATA  MyApp.EXE > first.txt
           
If Myapp.exe is built again at a different time, then use DUMPBIN as follows:
   DUMPBIN  /RAWDATA  MyApp.EXE > second.txt
           
You can now compare first.txt and second.txt using a file compare utility like:
       FC /B first.txt second.txt

抱歉!评论已关闭.