Learn what shellcode is, test small machine-code programs, and redirect a vulnerable program to shellcode you provide.
Start with the "Start here" resource below. It explains system calls, walks through a tiny hand-written program byte by byte, and covers bad bytes, executable memory, setuid programs, and how a leaked address lets you jump to your own code. Suggested order: shellcode-tester, then ret2shellcode-64.