Some notes on upgrading basic shells

https://sushant747.gitbooks.io/total-oscp-guide/content/privilege_escalation_-_linux.html
https://book.hacktricks.xyz/linux-hardening/linux-privilege-escalation-checklist
https://github.com/swisskyrepo/PayloadsAllTheThings/blob/master/Methodology%20and%20Resources/Linux%20-%20Privilege%20Escalation.md

https://0xffsec.com/handbook/shells/full-tty/
https://book.hacktricks.xyz/generic-methodologies-and-resources/shells/full-ttys

Linux - upgrade to Bash

BASH :

export TERM=xterm
SHELL=/bin/bash script -q /dev/null

SHELL=/bin/bash script -q /dev/null

exec /bin/bash 0&0 2>&0

PYTHON :

python -c 'import pty; pty.spawn("/bin/bash")'

exit_code = os.system('/bin/sh') output = os.popen('/bin/sh').read()

RUBY

exec “/bin/sh”

You have no rights to post comments