0

Is there any way from a kernel module to track which all page is written in heap ,

when user application write to a malloced page( example like given below ptr[1] =3) ?

The real use of this is , i am writing a kernel module which will dump only modified heap page of the user process

int main()
{
        char *ptr;
        ptr = malloc(10);

        ptr[1] =3;
        return 0;

}
Abhilash V R
  • 247
  • 4
  • 14
  • What do you mean `modified` heap page? And please note that `malloc` can use `brk` as well as `mmap`. – Ilya Matveychikov Jun 14 '12 at 11:54
  • Modified i meant ,if we write some value into that page(ex ptr[1] =3) or modify it again like ptr[1] = 12.Essentially from kernel module i want to check every write to that page – Abhilash V R Jun 15 '12 at 06:32
  • First of all, take a look at page fault handler. Next, learn how MMU works, i.e. how CPU and Linux manages page frames. Your task has a complex solution. – Ilya Matveychikov Jun 16 '12 at 07:30

0 Answers0