7. Find a Jump Point
The mona jmp command can be used to search for jmp (or equivalent) instructions to a specific register. The jmp command will, by default, ignore any modules that are marked as aslr or rebase.
The following example searches for "jmp esp" or equivalent (e.g. call esp, push esp; retn, etc.) while ensuring that the address of the instruction doesn't contain the bad chars \x00, \x0a, and \x0d.
The mona find command can similarly be used to find specific instructions, though for the most part, the jmp command is sufficient:
Choose an address from the log window and update your exploit.py script, setting the retn
variable to the address, written backwards (if the system is little endian). For example if the address is \x01\x02\x03\x04
in Immunity, write it as \x04\x03\x02\x01
in your exploit.
Last updated