Inconsistent register values after setting up them in a Jprobes module

19 views Asked by At

This question is in continuation to my previous question on Intercepting ELF loader.

Now the exact problem is that previously the code logic was implemented within the load_elf_binary function wherein at the end of the function eax, ebx, ecx and edx registers were set via an inline asm call, just before the function returned.

I have planted a jprobe on the load_elf_binary function as I need to access the struct linux_binprm *bprm argument but since I set the register values within the jprobe handler it causes an inconsistency when the control returns to the actual function and the application terminates with a segmentation fault.

What could be a possible solution to this ?

0

There are 0 answers