Re: Syscall table AKA hijacking syscalls

From: Matti Aarnio
Date: Fri Jan 02 2004 - 08:09:59 EST


On Fri, Jan 02, 2004 at 01:59:08PM +0100, Libor Vanek wrote:
> Hi,
> I'm writing some project which needs to hijack some syscalls in VFS
> layer. AFAIK in 2.6 is this "not-wanted" solution (even that there are
...
> So what is proper (Linus recommanded) way to do such a things? Create
> patches for specific syscalls like "if this_module_installed then
> call_this_function;" or try to force things like syscalltrack to go into
> vanilla kernel some time? Because what I've found out there are more
> projects which suffer from this restriction.


Maybe:

int (*funcvec_v1)(args);
EXPORT_SYMBOL(funcvec_v1);

...

retval = (funcvec_v1) ? (funcvec_v1)(args..) : func_f1(args...);

or something of that kind.

There is, of course, whole slew of politically coloured
issues with this chainability.


> --
> Libor Vanek

/Matti Aarnio
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/