Find the check, then decide: read it or defeat it
5 min read
Every crackme has a moment where it decides pass or fail — a compare, then a conditional jump. Find that branch and you have two moves:
- Read the key. If the check is
input == "s3cr3t", the answer is in the compare. If it istransform(input) == constant, invert the transform. This is the honourable solution and the one that teaches you the program. - Patch the branch. Flip the conditional jump (
je↔jne) or NOP it so every input "passes". Fast, and the right move when the check is one-way (a hash) and you only need the program to run — but it gives you the door, not the key.
In a debugger the same branch is where you set a breakpoint and inspect the registers at the compare: the value your input was turned into, and the value it is measured against, side by side. That comparison is the answer, made visible.