Installing an SSL/TLS Certificate for Qmail
To install a custom SSL/TLS certificate for Qmail on a Plesk server:
Create a combined
To create a combined
.pemcertificate file, start your favorite text editor and paste the contents of each certificate file and the private key in the file in the following order:
- The private key
- The primary certificate
- The intermediate certificate
- The root certificate
Make sure that you include the begin and end tags of the key and each certificate including the dash lines. The resulting text should look like this:
-----BEGIN RSA PRIVATE KEY----- .......... (Your Private Key here) .......... -----END RSA PRIVATE KEY----- -----BEGIN CERTIFICATE----- .......... (Your Primary SSL/TLS certificate here) .......... -----END CERTIFICATE----- -----BEGIN CERTIFICATE----- .......... (Your Intermediate certificate here) .......... -----END CERTIFICATE----- -----BEGIN CERTIFICATE----- .......... (Your Root certificate here) .......... -----END CERTIFICATE-----
Save the combined certificate file as
Log in to a Plesk server through SSH as a root user.
Download the combined certificate file
Make a backup copy of the existing default SSL/TLS certificate for Qmail.
For example for RedHat or Fedora operating systems, the SSL/TLS certificate file that you need to back up is
Note: For other operating systems, the default certificate file location may be different.
Open the default certificate file
/var/qmail/control/servercert.pemusing your favorite text editor, and replace the contents of the file with the contents of the combined certificate file
Save and close the file.
To finish the certificate installation, restart Qmail.