This question already has an answer here:
I need to add code into an assembled program. If I am only changing a jump, I change JE to JNE and that is simple. If I need to add only a couple of instructions, I can find a section with a bunch of NOP's and jump to that section, insert my new code, and then jump back.
What do I do if I need to insert about 10 lines of instructions and I do not have a section of NOP's that is large enough to fit my new code? I know I can not move any of the existing code since that would throw off any calls or jumps. I am trying to update the disassembled code in OLLYDBG since all I have is the executable.
Any suggestion on how to do this would be appreciated.