I don't think what you are trying to do is possible. Even if you somehow
managed to write over the code segment of a user space process (which I
very much doubt would be possible as I assume the memory is mapped
read-only), as soon as the kernel pages out (i.e. discards!) some portion
of the executable due to memory shortage your changes would be lost, since
the paging back into memory would happen by reading the executable back
from disk, which would mean it would read the unmodified code into memory...
Why would you want to do such a thing anyway? Kernel modifying userspace
binaries in memory sounds like a really flawed idea which is just begging
for problems. - Just recompiling the user space program with the smallest
change would make the new binary code incompatible with your predefined
module...
But perhaps I misunderstood you?
Anton
-- "I've not lost my mind. It's backed up on tape somewhere." - Unknown-- Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @) Linux NTFS Maintainer / WWW: http://linux-ntfs.sf.net/ ICQ: 8561279 / WWW: http://www-stu.christs.cam.ac.uk/~aia21/- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/