how to protect dll from replacement.

A

AbdulMunaf

Hi,

I have one executable say program.exe which is linked with first.dll.
first.dll contains TestClass. Now if i replace the first.dll with the
dll of same name and same exported function of class TestClass, but
having different implimentation, then the program.exe is executed with
replaced first.dll.

Is there any way to know that the first.dll is replaced or not.

Regards
 
T

titancipher

You could try hashing the DLL (e.g. sha-1), and compiling the hashes
into program.exe. Your program can then hash the first.dll before
loading it. If the hashes differ, it has been replaced. The issue
with doing it this way is if you change first.dll, you have to re-hash
it, and re-link the program.exe.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,301
Messages
2,571,549
Members
48,295
Latest member
JayKillian
Top