Skip to content

Instantly share code, notes, and snippets.

@dejisec
Last active July 15, 2020 19:59
Show Gist options
  • Save dejisec/cc791dac08c0b52381aadf1812446384 to your computer and use it in GitHub Desktop.
Save dejisec/cc791dac08c0b52381aadf1812446384 to your computer and use it in GitHub Desktop.

Python 2

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

Python 3

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

Bash

echo os.system('/bin/bash')

Perl

perl -e 'exec "/bin/bash";'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment