I am writing a simple C++ application that allows the user to test the app IF they have a password.
I would like to prevent the casual cracker from modifying the code to bypass this password check.
Here is some psuedocode:
if(!password){
// Quit program
}
and in assembly might result in some sort of TEST or JNE or some other JMP, right?
Let's say I am done with my program, and see where the patch could be made, for example, let's say here:
TEST EAX, EAX
JNE somewhere
So I know to look for a NOP at the JNE somewhere, which would bypass the check.
How would I prevent this in my C++ program? Is it even possible?
Any help would be greatly appreciated!
Regards.
Trope
I would like to prevent the casual cracker from modifying the code to bypass this password check.
Here is some psuedocode:
if(!password){
// Quit program
}
and in assembly might result in some sort of TEST or JNE or some other JMP, right?
Let's say I am done with my program, and see where the patch could be made, for example, let's say here:
TEST EAX, EAX
JNE somewhere
So I know to look for a NOP at the JNE somewhere, which would bypass the check.
How would I prevent this in my C++ program? Is it even possible?
Any help would be greatly appreciated!
Regards.
Trope