tum-i4 / self-checksumming

10 stars 6 forks source link

Use diff to find placeholders #4

Open mr-ma opened 7 years ago

mr-ma commented 7 years ago

If by any chance the binary contains a value equal to one of the placeholders patching will corrupt the binary. A better approach would be to use diff on two identical builds with different placeholders. Placeholders can use sequential ids instead of random numbers. In the first build we use even ids, subsequently in the second build we use odd ids. Now, a diff on the two binaries can correctly identify the exact placeholders, even in presence of placeholder equivalent values.