[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: added memory protection from kernel 2.6.11 --> 2.6.12 ?




I was wondering if the current kernels (=>2.6.12) have some kind of additional
memory protection addded.
Specifically, I'm trying to read from the process memory of another
process (using gdb) which works just fine on kernel version up to (and
including) 2.6.11.
(This is inevitable for me since I'm currently playing with
format string vulnerabilities to understand these kind of attacks.)
I would like to know how to turn the mentioned protection off.
If it is not possible, it would be great to get some hint which kernel code I
would have to patch/modify to turn it off ;)

I'm really no expert when it comes to linux kernel internals, but if you could read the memory of another process on a multitasking OS (without any guards), you should drop that OS ASAP. The only way in linux to attach to another process is (AFAIK) the ptrace call, and that's what you probably want to use (or rather, you will use a frontend like "gdb program pid", to attach to a running process.)

Your first example probably just works because the memory at this first instance of myshell is also a valid address in the second instance.

In the second example that's not the case. And in your third example, you also tried a valid memory address of the second instance of your process.

Willi



Reply to: