Hi there! A beginner question. I want to path some adresses in a jmp instruction in the code segment by overwriting the address with a mov, but the debugger tells me that I am not allowed to write to this part of the memory. I suppose, because the .code segment is read only in the PE image. How can I tell the TASM or the TLINK that the could segment is writable? Thanks!
Posted on 2001-07-03 09:42:00 by Warhawk
You can use a tool named: PeSAM (PE Section Attribute Modifier) http://www.programmerstools.com/files/utilities/pesam.zip
Posted on 2001-07-03 10:05:00 by elmenda
Either do that or tell the linker that the code section of your program is writeable with this linker switch: /SECTION:.text,EWR Bye! Latigo
Posted on 2001-07-03 11:35:00 by latigo
If you only need to patch your code at a single point in time, it's probably better to use VirtualProtect to temporarily make the code writable, then make in unwritable afterwards...
Posted on 2001-07-03 18:28:00 by f0dder