After reading the above, chroot will execute files in the /tmp directory. We have to create an executable and that we want to run in that directory. We do so with the following command.
Creating our listener and waiting a bit, we eventually get a root shell.