Ubuntu: How To Create a SSL Certificate
07-23-2014, 07:58 AM
(This post was last modified: 08-11-2014, 02:20 AM by TGates.)
How To Create a SSL Certificate
Enable SSL on you server
1: enable apache2 ssl
Setup ssl on you server
2: make a folder to the crt and key files
change name with your username
3: Create a Self Signed SSL Certificate
output
follow this -->
Setup SSL to website
4: now log on to you zpanel and go to
and select domain
5: under Custom Entry:
enter
now wait to Daemon has run take about 5 min
now hXXps://sitename.tld Works
XX = tt
Enable SSL on you server
1: enable apache2 ssl
Code:
sudo a2enmod ssl
sudo service apache2 restart
Setup ssl on you server
2: make a folder to the crt and key files
Code:
sudo mkdir /var/zpanel/hostdata/name/ssl
change name with your username
3: Create a Self Signed SSL Certificate
Code:
sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /var/zpanel/hostdata/name/ssl/sitename.key -out /var/zpanel/hostdata/name/ssl/sitename.crt
output
Code:
Generating a 2048 bit RSA private key
.............+++
................+++
writing new private key to '/var/zpanel/hostdata/name/ssl/sitename.key'
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Code:
Country Name (2 letter code) [AU]:US
State or Province Name (full name) [Some-State]:New York
Locality Name (eg, city) []:NYC
Organization Name (eg, company) [Internet Widgits Pty Ltd]:Name of company
Organizational Unit Name (eg, section) []: just press enter
Common Name (e.g. server FQDN or YOUR name) []: website name example.com
Email Address []:Email
Setup SSL to website
4: now log on to you zpanel and go to
Code:
Module Admin --> Apache Config --> Override a Virtual Host Setting
5: under Custom Entry:
enter
Code:
</VirtualHost>
<VirtualHost *:443>
ServerAdmin Email
ServerName websitename.tld
DocumentRoot /var/zpanel/hostdata/name/public_html/website
SSLEngine on
SSLCertificateFile /var/zpanel/hostdata/name/ssl/sitename.crt
SSLCertificateKeyFile /var/zpanel/hostdata/name/ssl/sitename.key
now wait to Daemon has run take about 5 min
now hXXps://sitename.tld Works
XX = tt