When executing a shell for educational purposes using shellcode, sometimes you need to make a full shell so you can use utilities such as
su. To do this, simply use python3 to spawn
bash without dropping setuid privileges.
python -c 'import pty;pty.spawn(["bash", "-p"])'