This are just important stuff that I have used.
Managing inputs for payload injection
$> ./program $(echo -ne "\xef\xbe\xad\xde")
(gdb) run $(echo -ne "\xef\xbe\xad\xde")
$> ./program ./myfile.txt
(gdb) run myfile.txt
$> cat ./mycommands.txt | ./program || echo -ne "\xef\xbe\xad\xde" | ./program
(gdb) run < ./mycommands.txt
# or
run < <(echo -ne "\xef\xbe\xad\xde")
$> echo -ne "\xef\xbe\xad\xde" | nc -vv localhost 666
# keep stdin open after injection
(cat ./mycommands.txt; cat) | ./program
# or
$> (echo -ne "\xef\xbe\xad\xde"; cat) | ./program
# or
$> (echo -ne "\xef\xbe\xad\xde"; cat) | nc -vv localhost 666
Breaking at main in stripped binaries
# option 1
set breakpoint pending on
starti
break __libc_start_main
continue
b *$rdi
continue
# option 2
set breakpoint pending on
set $base = 0x555555554000
b *($base+offset)