How can i determine binary files are not corrupted in Delphi 7? -


currently stuck question how can can decide , programmatically , whether file ( binary , zip or exe etc.) broken or not . mean , how windows decide binary file incomplete ?

can guide me in right direction ? looking : zip & exe

thanks

zip files (as many other archive formats) contain checksum (e.g. crc32) allows verify integrity of file. pe header (for .exe files) contains sizes of file sections allow perform checks.

in common case, there no means verify integrity of binary file unless there additional information file (and can built in file itself). crc32 code , md5 or sha1 hashes used check whether file corrupted or not.


Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

c++ - qgraphicsview horizontal scrolling always has a vertical delta -