I'm modifying a Win32 PE executable. I want to add another code section and, after that, I wanna modify the entry point to point out the new code section. Can this be true? Please masters... I'm Korean and my English is very poor. So sorry about that... Thank you for reading this. Have a nice day! :=)
Posted on 2001-03-28 07:53:00 by nyam
Hi, This is quite possible. The easiest way is to use a PE editor such as PEditor 1.7 for example: http://www.suddendischarge.com/download.query?id=0x1E4E7A5A You can add a section in the PE Header and call it anything you like. Then add as many bytes as you need to the file with a hex editor. Just make sure you use a multiple of the Section Alignment size (usually 1000 bytes). In the PE Header you will also need to increase the Size of the file, specify the Raw and Virtual sizes of the new section, and set the Code Characteristics of your new section to E0000020 or 60000020 so it is recognized as an executable section. Then you can change the entry point of the program to the new section using the PE editor. There are some specific programs around which will *just* add a new section for you as well. Hope this helps, Kayaker
Posted on 2001-03-28 13:05:00 by Kayaker