lkml.org 
[lkml]   [2011]   [Dec]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: Intercepting system calls
From
On Fri, Dec 23, 2011 at 10:22 AM, Gaurav Saxena <grvsaxena419@gmail.com> wrote:
> Hello Richard
>
> On Fri, Dec 23, 2011 at 2:46 PM, richard -rw- weinberger
> <richard.weinberger@gmail.com> wrote:
>> On Fri, Dec 23, 2011 at 10:08 AM, Gaurav Saxena <grvsaxena419@gmail.com> wrote:
>>> Ok I have seen details of KPROBES, I think it will suit to my
>>> requirements, I just wanted to know a few things,
>>> Can I use probes to prevent unlink of certain files? Also is
>>> CONFIG_KPROBES set to "y" on linux kernels available with distros like
>>> ubuntu?
>>
>> Kprobes allow you to instrument the kernel.
>> AFAIK it enabled by most distros.
> Can I use probes to return immediately ie. without execution of
> original system call. For example I put a entry probe on unlink and
> then on the probe return value unlink code is executed or not. Is that
> possible ?
> Also can I call a userspace function from kernel code? Would that be insecure ?

Using Kprobes you can do nearly anything.
But I would be surprised if you find a acceptable and sane solution.

--
Thanks,
//richard


\
 
 \ /
  Last update: 2011-12-23 10:29    [W:0.318 / U:0.228 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site