Subject: Re: Intercepting system calls
To: Girish Wadhwani <firstname.lastname@example.org>
From: Matthew Mondor <email@example.com>
Date: 04/21/2002 04:01:33
On Tue, 23 Apr 2002 09:09:03 +0800
"Girish Wadhwani" <firstname.lastname@example.org> wrote:
> Is there any way for a parent process to intercept a childs system call in NetBSD?
Intercept in what way exactly? For any userspace process to be able to specify it's
own stub functions for syscalls which it's child processes are executing? To customize
those or simply to be notified?
You may want to look at ktrace code, it also would be pretty easy to provide either a libc
patch or an alternate library mapping those syscall stub functions, your child processes
being linked with it would call your own... If it's to provide a compatibility layer,
the kernel emul code would be the place to look at