Can I use the same SSL certificate for smtp, imap, pop3 and http?

Solution 1:

The short answer is that yes a single certificate can be used for all those services.

The key and certificate can be stored in many formates, and using the openssl tool you can convert your key and certificate to other formats.

The real barrier is can you get a certificate that is valid for all the names that you wish to use. For your web you might want to use www.example.com, and for your mail you might want to use mail.example.com. You can get a wildcard or SAN certificate that will cover lots of names, but these cost more. It may be cheaper to get a couple individual certificates. The prices for different certs are different, so take some time and work out which will be cheaper in your case.

Solution 2:

Generally speaking, yes, although it can take a bit of work with various tools to convert the cert into the right format. I've used the same SSL cert with apache, dovecot (imaps) and postfix (for TLS).

openssl (along with simply cat'ing together the cert and key into the same file) has provided what I needed to do that.

Specifics vary, but I'm strongly of the opinion that you can in fact convert a signed ssl cert into whatever format you need, and I'm not aware of any exceptions in the use cases you mention.

Solution 3:

We are currently using wildcard certificate for all our services. As folks already mentioned all you need is openssl in order to convert it into formats required by your applications. So far we are using it for Apache httpd, OpenLDAP and mail (Zimbra). We used to buy certificates from Thawte but for this one we went with GoDaddy - it is way cheaper.