How gdb's 'attach' command work ? - Security

This is a discussion on How gdb's 'attach' command work ? - Security ; Hi everyone, I wanna know why the gdb's 'attach' command can work? In the virtual memory enviornment,Does it say that a program can't direct 'invade' another's processs's space? Please tell me the reason why gdb can do so... thnx...

+ Reply to Thread
Results 1 to 2 of 2

Thread: How gdb's 'attach' command work ?

  1. How gdb's 'attach' command work ?

    Hi everyone,
    I wanna know why the gdb's 'attach' command can work?
    In the virtual memory enviornment,Does it say that a program can't
    direct 'invade' another's processs's space? Please tell me the
    reason why gdb can do so...


    thnx

  2. Re: How gdb's 'attach' command work ?

    On 2007-11-20, xi4oyu wrote:
    > I wanna know why the gdb's 'attach' command can work?
    > In the virtual memory enviornment,Does it say that a program can't
    > direct 'invade' another's processs's space? Please tell me the
    > reason why gdb can do so...


    I think you just misunderstand the statement about virtual memory.
    Virtual memory is separate for each process, so the process may think
    that it's the only process in memory. But since the virtual memory is
    actually stored in RAM (or swap), then of course kernel has access to
    that memory and may provide such access to programs that need it. So no
    process can directly access the memory of another process, but some
    process may request from kernel indirect access to the memory of another
    process.


    --
    Minds, like parachutes, function best when open

+ Reply to Thread