any function arguments go through the CPU registers (rdi, rsi, rdx, etc);
we can store a dlopen() argument (path to the payload library) in the rbx register as it's value supposed to be preserved even after calling other functions;
don't forget about a stack (50*1024 bytes of it seems to be OK);
Some notes:
rdi
,rsi
,rdx
, etc);dlopen()
argument (path to the payload library) in therbx
register as it's value supposed to be preserved even after calling other functions;50*1024
bytes of it seems to be OK);