Hak5 C2
Jump to navigation
Jump to search
Contents
- 1 About
- 2 Installation Guide
- 2.1 Step 1. Update, upgrade, and clean your machine.
- 2.2 Step 2. Install required packages.
- 2.3 Step 3. Open ports depending on your needs (20, 2022, 80, 8080, 443).
- 2.4 Step 4. Download and unzip the community ZIP files in the tmp directory.
- 2.5 Step 5. Move the c2_community* file to usr/local/bin, and create the require database directory.
- 2.6 Step 6. Create a new systemd service to run the Hak5 C2 script.
- 2.7 Step 7. Utilize a template below, or build your own.
- 2.8 Step 8. Reload the systemd daemon, enable the service, and start.
- 2.9 Step 9. View the status of your service in order to view your key.
- 2.10 Step 10. Visit your website and fill in the required information to finalize.
- 2.11 Step 11. Sign into your Hak5 C2 website.
- 2.12 Step 12. Add devices, export logs, and more!
About
Installation Guide
Step 1. Update, upgrade, and clean your machine.
sudo apt -y update && sudo apt -y upgrade && sudo apt clean
Step 2. Install required packages.
sudo apt -y install unzip ufw
Step 3. Open ports depending on your needs (20, 2022, 80, 8080, 443).
sudo ufw allow 22,2022,80,8080,443/tcp && sudo ufw enable && sudo ufw reload
Step 4. Download and unzip the community ZIP files in the tmp directory.
sudo wget https://c2.hak5.org/download/community -O /tmp/community && sudo unzip /tmp/community -d /tmp
Step 5. Move the c2_community* file to usr/local/bin, and create the require database directory.
sudo mv /tmp/c2_community-linux-64 /usr/local/bin && sudo mkdir /var/hak5c2
Step 6. Create a new systemd service to run the Hak5 C2 script.
sudo vim /etc/systemd/system/hak5.service
Step 7. Utilize a template below, or build your own.
Template A (https)
[Unit] Description=Hak5 C2 After=hak5.service [Service] Type=idle ExecStart=/usr/local/bin/c2_community-linux-64 -hostname IPAddressORHostname -https -db /var/hak5c2/c2.db [Install] WantedBy=multi-user.target
Template B (http)
[Unit] Description=Hak5 C2 After=hak5.service [Service] Type=idle ExecStart=/usr/local/bin/c2_community-linux-64 -hostname IPAddressORHostname -db /var/hak5c2/c2.db [Install] WantedBy=multi-user.target
Template C (http / port 80)
[Unit] Description=Hak5 C2 After=hak5.service [Service] Type=idle ExecStart=/usr/local/bin/c2_community-linux-64 -hostname IPAddressORHostname -listenport 80 -db /var/hak5c2/c2.db [Install] WantedBy=multi-user.target
Step 8. Reload the systemd daemon, enable the service, and start.
sudo systemctl daemon-reload && sudo systemctl enable hak5.service && sudo systemctl start hak5.service
Step 9. View the status of your service in order to view your key.
sudo systemctl status hak5.service