Cloud C²
Search…
Cloud C² Setup with Self-Signed SSL certificates
By default when using the -https flag with the Cloud C² binary, a Let's Encrypt certificate will be used. In the case that you wish to provide a self-signed certificate, please note the following additional deployment details:
1) When generating the certificate, the Common Name must be the IP address or FQDN of the server. See this example:
1
Our self-signed certificate was generated like this:
2
(192.168.0.119 is the IP address of the machine running the Hak5 Cloud C2 server)
3
4
openssl req -newkey rsa:2048 -x509 -sha256 -days 3650 -nodes -out cert.crt -keyout cert.key
5
6
Country Name (2 letter code) [AU]:GB
7
State or Province Name (full name) [Some-State]:Manchester
8
Locality Name (eg, city) []:Manchester
9
Organization Name (eg, company) [Internet Widgits Pty Ltd]:Hak5
10
Organizational Unit Name (eg, section) []:Developers
11
Common Name (e.g. server FQDN or YOUR name) []:192.168.0.119
12
Email Address []:[email protected]
Copied!
2) When provisioning the device, in addition to copying the device.config file to /etc/, the generated cert.crt must be appended to the cert.pem file in /etc/ssl/.
1
1) SCP the resulting cert.crt to your devices, in "/etc/ssl/certs"
2
2) SSH into your device
3
3) Execute "cd /etc/ssl"
4
4) Execute "cat certs/cert.crt >> cert.pem"
5
5) Reboot the device
6
7
The device should now successfully check-in to the Hak5 Cloud C2
Copied!
3) the command line arguments should be passed in the order -hostname, -https, -keyFile and -certFile
1
./c2_pro-linux-64 -hostname 192.168.0.119 -https -keyFile /var/hak5c2/cert.key -certFile /var/hak5c2/cert.crt
Copied!
From version 3.0.0 onward all, Cloud C² editions (Community, Edition, Teams) use the same binary. Filenames for Cloud C² will differ from example — however all parameters remain the same.
Copy link