Click here to Skip to main content
15,885,092 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
I am trying to implement self integrity check in MFC exe.

Ref : -
Tamper Aware and Self Healing Code

I dumped text section.
C++
    ofstream myfile;
myfile.open ("textsec.bin");
myfile.write((const char*)pCodeStart,dwCodeSize);
myfile.close();


Every time its different so hash for it is also different. Please Help.
Posted
Updated 3-Dec-13 5:45am
v2
Comments
Sergey Alexandrovich Kryukov 3-Dec-13 12:24pm    
So what? It's different because you change it. Help with what?
—SA
omkarpardeshi123 4-Dec-13 3:27am    
If we implement Tamper Aware and Self Healing Code in console application it works fine . But if we try to implement it in MFC application we cant. because hash of text i.e. code section from memory we calculate is different every time. I want to know why this happens can we stop this ?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900