>>7
Protected address spaces don't really pose a problem for this, so...
Name:
Anonymous2008-03-09 14:58
>>24
He wants to write a program that edits the code in memory of another program which is already running. On every modern OS except certain research OSes, this very much won't be allowed.
>>25
If you've got the permissions, it can be arranged. Or failing that, you can bribe in cash.
And then there's always #pragma pretty please.
Anyway, you're the only one that mentioned the word 'code' in this thread so far. You're also the only one who mentioned 'wants', 'which', 'already', 'every', 'modern', 'OS', 'except', 'certain', 'research', 'very', 'much', 'won't' and 'allowed', but that's just useless trivia.
Name:
Anonymous2008-03-10 2:11
PTRACE(2) Linux Programmer's Manual PTRACE(2)
NAME
ptrace - process trace
SYNOPSIS
#include <sys/ptrace.h>
int ptrace(int request, int pid, int addr, int data);
DESCRIPTION
Ptrace provides a means by which a parent process may con-
trol the execution of a child process, and examine and
change its core image. Its primary use is for the imple-
mentation of breakpoint debugging. A traced process runs
until a signal occurs. Then it stops and the parent will
be notified with wait(2). When the process is in the
stopped state, its memory can be read and written. The
parent can also cause the child to continue execution,
with optional ignoring the signal which caused stopping.
The value of the request argument determines the precise
action of the system call:
PTRACE_TRACEME
This process is to be traced by its parent. The
parent should be expecting to trace the child.
PTRACE_PEEKTEXT, PTRACE_PEEKDATA
Read word at location addr.
PTRACE_PEEKUSR
Read word at location addr in the USER area.
PTRACE_POKETEXT, PTRACE_POKEDATA
Write word at location addr.
PTRACE_POKEUSR
Write word at location addr in the USER area.
PTRACE_SYSCALL, PTRACE_CONT
Restart after signal.
PTRACE_KILL
Send the child a SIGKILL to make it exit.
PTRACE_SINGLESTEP
Set the trap flag for single stepping.
PTRACE_ATTACH
Attach to the process specified in pid.
PTRACE_DETACH
Detach a process that was previously attached.
NOTES
init, the process with process ID 1, may not use this
function.
RETURN VALUE
On success, zero is returned. On error, -1 is returned,
and errno is set appropriately.
ERRORS
EPERM The specified process (i.e., init), cannot be
traced, or is already being traced.
ESRCH The specified process does not exist.
EIO Request is not valid.
CONFORMING TO
SVr4, SVID EXT, AT&T, X/OPEN, BSD 4.3
SEE ALSO
gdb(1), exec(3), signal(2), wait(2)
Linux 0.99.11 23 July 1993 1
Name:
Anonymous2008-03-10 4:58
>>7
Is anyone going to explain debuggers and DLL injection to this guy?
Name:
Anonymous2008-03-10 10:26
>>37
What's so perplexing about a debugger or DLL "injection" in particular?
Name:
Anonymous2008-03-10 11:15
>>38
It may be difficult for novice programmer to use debugger or DLL "injection" in particular
>>7
Actually windows has no protected pages, it even disables the hardware paging that comes with 80286 and better processors just to be simple. You can also just monitor the socket that sends a log of all IO events, interrupts and exceptions back to msn.com, it's written in %windir%\system32\NTsoc\{2984s-324938-a5543c}.