May
05

Debugging Plesk

If you want to debug Plesk, i.e. with gdb, be aware that Paralells made many efforts to prevent you from doing so. A pain for everyone who has to deal with strange and stupid Segmentation Faults or what to fix Plesk for this r another reason. I was thinging IONCube was enough (which is still easy to break) but hey, let’s start debugging Plesk internals first.

Parallels used a similar trick to Apple with iTunes which involved ptrace() calls in masses. The trick is to set a breapoint in gdb on it to prevent it from execing.

(gdb) break ptrace

is good enough :) Ok, if you now break into a ptrace(), just go type “return” and “cont” and everything will run fine.

If you need more comprehensive infos on how ptrace() works as a anti debuger meassure, read this page:http://steike.com/code/debugging-itunes-with-gdb/

It is a fairly interesting read.

 

top