I used make-dummmy-cert that comes with apache 2.2 and ssl_mod to make a self-signed certificate, I tried www.domain.com domain.com *.domain.com, none of them would work for both www.domain.com and domain.com. The browser would say The certificate is only valid for domain.com( or www.domain.com or *.domain.com respectively) how do I make a self-signed cert that would work for both cases?
Do you have the same content at domain.com and www.domain.com? As far as I understand this would be a bad idea for SEO and you should redirect one to the other using for instance mod_rewrite.
What I think you need to do if you really want to match both is to create a certificate with multiple
@Bill Weiss is right, I just checked one of the certs I have from GoDaddy and it has both www.example.com and example.com in the SubjectAltName, and both work in the browser. So it sounds like you can get what you need for cheap.
|show 1 more comment|