On my mail setup I'm currently using self signed certificate generated for server hostname.
And I'm curious is there some kind of SSL certificate that shared hosting providers use for multiple domains mail and how are they setting them up?
On my mail setup I'm currently using self signed certificate generated for server hostname.
And I'm curious is there some kind of SSL certificate that shared hosting providers use for multiple domains mail and how are they setting them up?
If you want each domain to use a valid SSL certificate, you have 2 solutions: use a multi-domain certificate, or set up each domain on a unique IP. The first solution is terrible: those certificates are usually quite expensive (though you can find inexpensive ones), they will list all of the domains you wish to certify on the same cert, and, most importantly, they are only issued once, so adding just one new domain means getting an entirely new cert.
The better solution is to place each domain on its own IP, and then to match each certificate to its respective IP.
Here's how you do it in postfix.
You will first place your certificates for each domain in the /etc/postfix/ directory (you can also create a /etc/postfix/ssl/ directory) Note: i use Plesk, which uses .pem certificate files, but you can also use .key and .cer files (.pem files are just a concat of .key and .cer file, in that order)
then, you need to modify the master.cf file in /etc/postfix/
originally, mine looked like this (probably because i added the last 3 IPs after i set up the server:
Now, to bind each certificate to its corresponding IP, you do as follows:
That's it!! (don't forget to comment out the original lines as seen above)
PS: to do the same for POP/IMAP if you use courier-imap, you simply place copies of those .pem files in /usr/share/courier-imap/ (or in the case of Plesk, you place them in /usr/share/ ) and you name them as follows: imapd.pem.xx.xx.xx.xx pop3d.pem.xx.xx.xx.xx
where xx.xx.xx.xx is the respective IP address (the 2 certificates are copies of the same file)
Hope this helps!