Abstract In 2006, Gaurav Gupta and Josef Pieprzyk presented an attack on the branch-based software watermarking scheme proposed by Ginger Myles and Hongxia Jin in 2005. The software watermarking model is based on replacing jump instructions or unconditional branch statements (UBS) by calls to a ngerprint branch function (FBF) that computes the correct target address of the UBS as a function of the generated ngerprint and integrity check. If the program is tampered with, the ngerprint and/or integrity checks change and the target address is not computed correctly. Gupta and Pieprzyk's attack uses debugger capabilities such as register and address lookup and breakpoints to minimize the requirement to manually inspect the software. Using these resources, the FBF and calls to the same is identi ed, correct displacement values are generated and calls to FBF are replaced by the original UBS transferring controlof the attack to the correct target instruction. In this paper, we propose ...