Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[c++ ][Help] File HashCheck

Experienced Elementalist
Joined
Nov 12, 2010
Messages
218
Reaction score
5
(DLL File)i need a code that checks for a file if the md5 hash or crc32 of the file dosent match then kill the process
 
Newbie Spellweaver
Joined
May 17, 2004
Messages
9
Reaction score
1
Checking it in file or memory?

If in memory you will probably need to walk the PE header to find the main mapped code section (usually starting at 401000h).
Also there could be possibly fix ups in the code that you would have to compensate for too.

Again if in memory you could also map in the file on disk and do a direct byte compare from memory vrs the image.

CRC32 is probably the way to go as it's generally faster for checking occasionally in memory.
But then it's more common and thus easier for reverser to locate, bake a fixed code, etc.
MD5 has a lot more bits so there is much less chance of a collusion, but then CRC32 should work fine.

Look on sites like CodeProject, GameDeception, etc., for some sample code to do MD5 and CRC32 hashes.
 
Back
Top