1. A method of protecting an executable program, the method comprising: receiving a copy of the executable program, the executable program comprising executable instructions arranged as a plurality of functional blocks; receiving a debug database associated with the executable program, the debug database storing the locations of the functional blocks within the executable program; identifying from the debug database the location of a functional block within the executable program; and inserting protection code into the executable program, the protection code overwriting at least part of the functional block, wherein execution of the functional block causes the protection code to be executed, and execution of the protection code performs an operation and executes a copy of the at least part of the functional block overwritten by the protection code.