Control Web Panel

WebPanel => SSL => Topic started by: sokki on March 18, 2015, 12:12:17 PM

Title: SSL for CWP itself
Post by: sokki on March 18, 2015, 12:12:17 PM
Hi Guys,

I've been trying to install a SSL for the panel itself with no avail. Anyone else had any luck.

This is a purchased SSL for the host istself for the CWP
Title: Re: SSL for CWP itself
Post by: sokki on March 18, 2015, 12:31:46 PM
problem solved.

change the SSL Cert paths in the CWP conf file

/usr/local/cwpsrv/conf.d/cwp-ssl.conf
Title: Re: SSL for CWP itself
Post by: spangler on April 13, 2015, 08:05:50 AM
Hi do you mind if you elaborate more? do I need to change everything or just the ssl path ?
Title: Re: SSL for CWP itself
Post by: hiperaktifdizayn on September 18, 2015, 02:38:57 AM
It was a month I could not solve my problem . Which file Is it possible to write more detailed where we put it?
Title: Re: SSL for CWP itself
Post by: Igor S. on September 18, 2015, 12:37:45 PM
Hi.

What kind problems do you have?
Title: Re: SSL for CWP itself
Post by: cubehost on March 06, 2016, 03:58:04 AM
Having fought with this issue myself for some time... Here is how I solved it:

Create a subdomain that is different than your CWP hostname and make sure that you have NS records for it that point to your CWP nameservers.
So for example - if you use cwp.example.com for the hostname, make another subdomain like cp.example.com

Create a new account in CWP for that subdomain - cp.example.com
Assign your SSL certificate, like you would for another user, to that account and domain in the SSL certificate manager in Apache settings.

Then edit /usr/local/cwpsrv/conf.d/cwp-ssl.conf
Code: [Select]
Listen 2031
<VirtualHost 192.168.0.1:2031>
        ServerName 192.168.0.1
        SSLEngine on
        SSLCertificateKeyFile /etc/pki/tls/cwp-192.168.0.1.key
        SSLCertificateFile /etc/pki/tls/cwp-192.168.0.1.cert
        SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown
</VirtualHost>

Replace the IP address and certificate locations with your subdomain and certificate locations from the account you created:

Code: [Select]
Listen 2031
<VirtualHost cp.example.com:2031>
        ServerName cp.example.com
        SSLEngine on
        SSLCertificateKeyFile /etc/pki/tls/private/cp.example.com.key
        SSLCertificateFile /etc/pki/tls/certs/cp.example.com.cert
        SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown
</VirtualHost>

Save the file and then restart CWP:
Code: [Select]
service cwpsrv restart

Now your ssl should work on that subdomain with the login page.

I tried to do this with the hostname I used, but I could never overcome the ssl_protocol errors I would get when I tried to visit the address.
The downside of this is that you have to create a separate account and subdomain.
Hopefully, this helped someone out there struggling to get this working as expected.
Title: Re: SSL for CWP itself
Post by: gfeyen on April 06, 2016, 05:04:39 PM
quick and dirty!


Listen 2031
<VirtualHost SERVER IP:2031>
        ServerName SERVER IP
        SSLEngine on
        SSLCertificateKeyFile /etc/pki/tls/private/hostname.key
        SSLCertificateFile /etc/pki/tls/certs/hostname.cert
        SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown
</VirtualHost>