win()
, and to do that you have to populate the register rdx
. Try what we've talked about, and then have a look at the answer if you get stuck.call
. This is because RBX ends up being 0
anyway, and you want to mess with the least number of registers you need to to ensure the best success.win()
written into it so that we can point r15
at it. I'm going to opt to call gets()
again instead, and then input the address. The location we input to is a fixed location of our choice, which is reliable. Now we just need to find a location.dcu main
to contiune until main. Now let's check permissions:0x404028
appears unused, so I'll write win()
there.gets()
:POP_CHAIN
a couple of intructions along: