I recently did something like this. I wrote a program called ptproxy that
uses ptrace() to catch ptrace() and wait() syscalls made by a debugger.
Then ptrace implemented these syscalls itself, applying them to another
process.
>From the README:
ptproxy spawns two children: a debugger and a program to be debugged.
ptproxy catches debugging calls from the debugger and forwards them
to the debugged program. The results are passed back to the debugger.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/