Originally Posted by poornaMoksha
Can we do something like this on Linux??
Yes, we have ptrace (instruction level tracing) , which can employ an anti debugging scheme (using PTRACE_TRACEME) but usually this is quite easy to bypass using utilities such as GDB , Check here
, basically till date we don't have any solutions which can protect your software from crackers (scripting's solution was quite rudimentary and can be easily bypassed , any cracker with some Assembly knowledge can simply use debuggers such as olly etc. and disable/delete that instruction). By employing these techniques we can only make it difficult for a cracker.
For some examples on cracking in linux , you can have a look at my tutorial series of crack me's